Re: [Zim-wiki] spell check on windows

2012-11-13 Thread klo uo
IMHO, not worth the trouble.
I tried and stucked after trying to pair enchant dependency to gtk-spell
package, which although properly installed (after much trouble) it simply
didn't accept any dictionary. It was awful experience I won't recommend to
anyone

Even Zim Windows installer doesn't have it


On Tue, Nov 13, 2012 at 12:47 PM, Charles Medcoff wrote:

> Is there a “recipe” for getting spellcheck to work on windows?
>
> ** **
>
> --chuck
>
> ___
> Mailing list: https://launchpad.net/~zim-wiki
> Post to : zim-wiki@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~zim-wiki
> More help   : https://help.launchpad.net/ListHelp
>
>
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Equation editor in Windows

2012-11-12 Thread klo uo
Just install MiKTeX


On Mon, Nov 12, 2012 at 6:12 PM, Jeff Cox  wrote:

> Hi all.
> I've successfully used the LaTeX equation editor on Ubuntu.  Just
> wondering if someone has a recommendation on how to get this working in
> Windows.
>
> Thanks,
> Jeff
>
>
> ___
> Mailing list: https://launchpad.net/~zim-wiki
> Post to : zim-wiki@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~zim-wiki
> More help   : https://help.launchpad.net/ListHelp
>
>
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


[Zim-wiki] Additional command line options in cmd plugins

2012-11-04 Thread klo uo
Insert equation / diagram / ditaa, plugins all share similar structure.
Even more ditaa plugins has left comments from diagram plugin ;)

I want to suggest allowing all these plugins to accept additional options
on insertion (on runtime).
For example for what I used ditaa plugin I changed the source and added
`-E` option to be by default (--no-separation). Maybe it could be handy to
set addtional parameters on insertion, without changing plugin source code
for the task.

Similarly, for equations inserted inline I want to use different dpi
option, then for those that aren't inlined, as inserting regular equation
in text will change vertical line spacing, and it won't look good as it
could.

Yet graphviz...

Changing plugins source may be some kind o workaround, but then editing
named item, will reflect current plugin setting.
And then if something like this gets accepted, where to store this options?
Probably it won't be too much complicated, as setting additional parameters
would not be something that user would do often, but again.

No high hopes, just thought to ask.

Cheers
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


[Zim-wiki] Instructions for building executable in Windows?

2012-11-04 Thread klo uo
Hi,

I'm happy with Zim now, after tweaking some minor issues, and wanted to
remove GTK from my Python packages, but first to create Zim executable.

`python setup.py py2exe` is not enough, and I found in the past that the
process of creating executables for large project is too complicated.

Looking at Zim home page I see:

> https://code.launchpad.net/zim 
> See build instructions in ./windows/README-BUILD-win32.txt

But can't find anywhere that file nor simple instructions to follow and
build Zim. Does such instructions exist? Or is there some simple guide how
to build Zim executable on Windows?

Thanks
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
On Tue, Oct 30, 2012 at 6:24 AM, klo uo wrote:
> 
> ...
> XDG_DATA_HOME = Dir(
> get_environ('XDG_DATA_HOME', os.environ['APPDATA'] + 
> '//zim//data'))
> ...
> 

Yet more issues, double forward slashes should be double backward
slashes, or else
Sorry, I just woke up :)

Here is revisited snippet: http://pastebin.com/raw.php?i=jVBKRzLZ

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
> 
> if os.name == 'nt':
> import _winreg as wreg

Heh, import should go after the "try", couple of lines bellow

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
On Mon, Oct 29, 2012 at 8:42 PM, Jaap Karssenberg wrote:
>> So that if user has config files as in zim 0.57 config folders, above
>> snippet will make it compatible to potentially new config folder
>> scheme?
>
> Yes, that is the idea.

That sounds great :)


>>> Probably the CACHE variable should go to a folder for temporary data.
>>> Not %TMP% because we want it available longer, but it can be flushed
>>> when space is needed on the system.
>>
>> I don't know about existence of other temporary folder except %TMP% and 
>> %TEMP%
>
> Isn't there a folder that is also used for things like temporary
> internet files ?

Sure, and by just looking in there I see Gimp also uses it for caching (gegl)

With SPL folder can be located by reading the registry (on any Windows version):


>>> import _winreg as wreg
>>> wreg_key = wreg.OpenKey(wreg.HKEY_CURRENT_USER, 
>>> r'Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders')
>>> wreg.QueryValueEx(wreg_key, "Cache")
(u'%USERPROFILE%\\Local Settings\\Temporary Internet Files', 2)


And:


>>> import os
>>> wreg.QueryValueEx(wreg_key, "Cache")[0].replace(u'%USERPROFILE%', 
>>> os.environ['USERPROFILE'])
u'C:\\Documents and Settings\\klo\\Local Settings\\Temporary Internet Files'
>>>wreg.CloseKey(wreg_key)



So, considering previous talk, something like this should be sensible
for Windows users:


if os.name == 'nt':
import _winreg as wreg
XDG_DATA_HOME = Dir(
get_environ('XDG_DATA_HOME', os.environ['APPDATA'] + 
'//zim//data'))

XDG_DATA_DIRS = Dir(
get_environ('XDG_DATA_HOME', '~/.local/share/'))

XDG_CONFIG_HOME = Dir(
get_environ('XDG_CONFIG_HOME', os.environ['APPDATA'] + 
'//zim//config'))

XDG_CONFIG_DIRS = Dir(
get_environ('XDG_CONFIG_HOME', '~/.config/'))

try:
wreg_key = wreg.OpenKey(wreg.HKEY_CURRENT_USER,
r'Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell
Folders')
cache_dir = str(wreg.QueryValueEx(wreg_key,
"Cache")[0].replace(u'%USERPROFILE%', os.environ['USERPROFILE']))
wreg.CloseKey(wreg_key)
except:
cache_dir = os.environ['TEMP']

XDG_CACHE_HOME = Dir(
get_environ('XDG_CACHE_HOME', cache_dir + '//zim'))


___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
On Mon, Oct 29, 2012 at 3:43 PM, Jaap Karssenberg wrote:
>
> The "XDG_xxx_DIRS" variables are lookup paths for system defaults for
> files not found in the corresponding "XDG_xxx_HOME" folder. So should
> probably include at least the fallback location.

If I read this right, then if "XDG_xxx_DIRS" are set to *nix
"XDG_xxx_HOME" values, they can serve as compatibility layer for user
already having data from previous version:


XDG_DATA_DIRS = Dir(
get_environ('XDG_DATA_HOME', '~/.local/share/'))

XDG_CONFIG_DIRS = Dir(
get_environ('XDG_CONFIG_HOME', '~/.config/'))


So that if user has config files as in zim 0.57 config folders, above
snippet will make it compatible to potentially new config folder
scheme?


> Probably the CACHE variable should go to a folder for temporary data.
> Not %TMP% because we want it available longer, but it can be flushed
> when space is needed on the system.

I don't know about existence of other temporary folder except %TMP% and %TEMP%

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
Hi Japp,


> This sounds like a reasonable proposal. Indeed setting XDG_DATA to the
> relevant path will change the lookup path for zim. Probably you'll
> also want to do something similar for XDG_CONFIG and XDG_CACHE.
>
> All these parameters are initialized in zim/config.py, feel free to
> patch it accordingly and submit the patch through a bug report.

I did this (diff -b):


99a100,103
>
>   if not 'APPDATA' in os.environ or not os.environ['APPDATA']:
>   os.environ['APPDATA'] = os.environ['HOME']
>
140a145,160
>   if os.name == 'nt':
>   XDG_DATA_HOME = Dir(
>   get_environ('XDG_DATA_HOME', os.environ['APPDATA'] + 
> '//zim//data'))
>
>   XDG_DATA_DIRS = Dir(
>   get_environ('XDG_DATA_DIRS', os.environ['APPDATA'] + 
> '//zim//data//zim'))
>
>   XDG_CONFIG_HOME = Dir(
>   get_environ('XDG_CONFIG_HOME', os.environ['APPDATA'] + 
> '//zim//config'))
>
>   XDG_CONFIG_DIRS = Dir(
>   get_environ('XDG_CONFIG_DIRS', os.environ['APPDATA'] + 
> '//zim//config//zim'))
>
>   XDG_CACHE_HOME = Dir(
>   get_environ('XDG_CACHE_HOME', os.environ['APPDATA'] + 
> '//zim//cache'))
>   else:


Local settings folders can be retrieved from registry, but that's
probably not so good idea

This proposed folder structure doesn't look very good, as Zim code is
made in respect to XDG suggestions and rest of the code will need
changes to make more proper Windows special folders pairing. But
that's not some big problem, and this way Zim config files will be in
one place where it's expected on Windows - %APPDATA% folder.

I tested these settings, but I'm just not sure about XDG_xxx_DIRS
variables and their role


> P.S. behavior is documented in the manual, so you could have saved a
> bit of trouble by looking there instead of going over the code ;)

Thanks. Good to know that manual includes technical details, which I
didn't expect ;)


Cheers

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


[Zim-wiki] Win32: configuration path

2012-10-29 Thread klo uo
Hi,

I run zim-0.57 from source on XP, and I arranged/mapped some topics
with appropriate PDF file links, then discovered that I can even
customize which application handles the link. Great!

However, the path to my custom application had spaces in it, and it
failed to launch. OK, figured that and opened "Configure applications"
dialog, but can't change already defined application, so I added new
one and surrounded path in quotes. Done, but there is no function to
remove already defined faulty application, so now I have two "Open
with..." functions with same name.

I started to look for file that stores this data. None in zim source
folder and subfolders, so I thought to look in my "home"
(%USERPROFILE%) folder. To my surprise Zim doesn't create it's own
folder in my "home" folder, but it just writes directly in it. This is
not so good. From available folders in my "home" folder I looked which
are used by Zim. Found some but no trace of the file I was looking
for.

Open "applications.py" to see what Zim is doing while setting custom
application. It writes data to
"XDG_DATA_HOME.file('applications/defaults.list')". OK, at least I
have the name of file and info about the folder name in which it
resides. After a while I found that wanted file is stored in:
%USERPROFILE%\.local\share\applications. These folders are created and
used only by Zim, although I do use other cross-platform application

Now I have a suggestion: If you are willing to change this behavior
for Windows users and their special folders
(http://en.wikipedia.org/wiki/Special_folder), please don't use just
%USERPROFILE% aka "os.path.expanduser('~')", as that's *nix setting.
Appropriate folder for storing application related data is set in env
variable %APPDATA%. Location for local application data which could
pair XDG_DATA_HOME, is not set in env variable in Windows XP, but it
is in Windows 7. Maybe you can just set XDG_DATA_HOME to
"%APPDATA%\zim" or use some instrument to reveal it for both XP/7/...


Thanks

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: GUI with native controls?

2012-10-25 Thread klo uo
Figured it out

I wasn't aware that I had ".gtkrc-2.0" file in my %USERPROFILE%
folder, put by some application perhaps

Everything smooth, now that plugins doesn't pop cmd windows and Zim
looks like rest of OS GUI


Cheers :)

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: GUI with native controls?

2012-10-25 Thread klo uo
On Wed, Oct 24, 2012 at 1:15 AM, Greg Warner wrote:
> Use "--standalone" to get zim to work with pythonw.exe.
>
> My windows instance of zim looks native to me and I don't recall doing
> anything special.

Thanks for the tip Greg,

Now I can run without attached console, but GTK looks the same unfortunately.
Do you maybe have any other idea, where from PyGTK reads it's configuration?

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: popup cmd windows; ditaa plugin; toolbar icons

2012-10-25 Thread klo uo
Changing line 156 in zim/applications.py:


p = subprocess.Popen(argv, cwd=cwd, stdout=open(os.devnull, 'w'),
stderr=subprocess.PIPE)


to:


if os.name == 'nt':
# http://code.activestate.com/recipes/409002/
startupinfo = subprocess.STARTUPINFO()
startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
p = subprocess.Popen(argv, cwd=cwd, stdout=open(os.devnull, 'w'),
stderr=subprocess.PIPE, startupinfo=startupinfo)
else:
p = subprocess.Popen(argv, cwd=cwd, stdout=open(os.devnull, 'w'),
stderr=subprocess.PIPE)


stops popup windows, and works great. As it should ;)


On Sun, Oct 21, 2012 at 11:22 PM, klo uo  wrote:
> 1. plugin commands (insert equation, insert dot graph, etc) open popup cmd
> windows when executed which I think looks bad. I browsed plugin folder and
> it seems like plugins call "zim.applications.Application" module for command
> execution, but this module is unavailable for user tweaks. I know that I can
> download Zim source, but then I have to install all dependencies which makes
> the task undesired. So my question is, is there any way I can remedy popup
> cmd windows while executing plugins?

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


[Zim-wiki] Win32: GUI with native controls?

2012-10-22 Thread klo uo
Hello again :)

I installed build requirement (all-in-one PyGTK package), downloaded
Zim source and executed Zim w/o "python setup.py install"
It works fine, and because it's executed from CLI it doesn't spawn cmd
windows on latex or diagram insertions, so I don't even have to look
in the code
And BTW pythonw.exe can't run zim.py for some reason, so I have no options

However now Zim GUI looks ancient and distracting from rest, or say it
ugly. I looked in default PyGTK gtkrc files and they are as expected
For example, file
"C:\Python27\Lib\site-packages\gtk-2.0\runtime\etc\gtk-2.0\gtkrc" is
pointing to what seems to right theme:

  gtk-theme-name = "MS-Windows"

I know Gimp uses this theme, and looks decent with regard to rest of
OS interface. Also previously downloaded portable Zim uses it, and
looks fine too.
But launching Zim from source, doesn't use this theme. I tried to make
etc folder structure inside Zim source, but it doesn't help

Any ideas?

___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


Re: [Zim-wiki] Win32: popup cmd windows; ditaa plugin; toolbar icons

2012-10-22 Thread klo uo
OK, thanks for confirmation

My main concern is 1st question, but then I guess I'll have to reconsider
downloading source package

ditaa was something I discovered through Zim, and thought to try it, maybe
could be handy. Could use it as custom tool, but Zim integrated latex
(miktex) and graphviz in so clever way, that I wanted this plugin to work
the same too ^_^

Thanks for considering Windows platform, as no many FOSS projects do it
right, for whatever reasons
I discovered Zim on Ubuntu, and was pleased to see Windows version which I
enjoy using it


Best wishes,
klo
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp


[Zim-wiki] Win32: popup cmd windows; ditaa plugin; toolbar icons

2012-10-21 Thread klo uo
Hi,

I use latest portable version on Windows XP and would appreciate if I could
get help on some of my questions:

1. plugin commands (insert equation, insert dot graph, etc) open popup cmd
windows when executed which I think looks bad. I browsed plugin folder and
it seems like plugins call "zim.applications.Application" module for
command execution, but this module is unavailable for user tweaks. I know
that I can download Zim source, but then I have to install all dependencies
which makes the task undesired. So my question is, is there any way I can
remedy popup cmd windows while executing plugins?

2. I have ditaa plugin, and made it available system wide by making batch
file in Windows root folder "java -jar ditaa.jar %*". Executing "ditaa" on
command line from any folder is without problem, but for some reason Zim
can't find the command available. Again it looks from above like
"zim.applications.Application" module is responsible for finding it.

3. This is just cosmetic question, as I couldn't find icon resources used
on toolbar and in menu bar. They aren't available as PNG files (except
couple of them in pixmap folder) and I can't find which DLL holds icon
resources?


Thanks
___
Mailing list: https://launchpad.net/~zim-wiki
Post to : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp