[pygtk] TextView / TextBuffer autoscroll to end

2003-09-07 Thread Martin Preishuber
Hi all,

I tried to solve the following small problem for the 3rd time now and
didn't find a solution, so I thought I'd ask here :) The problem is the
following:

I have a ScrolledWindow containing a TextView widget with a TextBuffer.
I insert text into the TextBuffer with .insert_at_cursor(text). Now that
works fine, except that the visible lines are always the first few
lines, so it doesn't scroll down automatically. 
How do I automatically scroll down to the latest line ? I played around
with TextView.place_cursor_on_screen(), scroll_iter() and co but with no
success :( Any ideas ?

Thanks,

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

Every young man should have a hobby: learning how to handle money is
the best one.
-- Jack Hurley

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


[pygtk] gnome applet and kde3

2003-06-29 Thread Martin Preishuber
Hi there,

I'm still trying to get a gnome applet working (gtk2), but since I use
KDE3 as desktop, there just doesn't appear anything ... is it basically
possible, that a gnome2 applet works with kde3 ? gaim is a gnome2 applet
and it works with kde3 so that should probably be possible.

If so, can anyone point me to some working code or send me an example I
can start with ? 

Thanks,

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

Everything takes longer, costs more, and is less useful.
-- Erwin Tomash

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


[pygtk] pygtk 1.99.12 vs. 1.99.15

2003-03-10 Thread Martin Preishuber
Hi there,

Just a short question, has there been a change in pygtk 1.99.15 compared
to 1.99.12 which affects GtkTextBuffer.insert_at_cursor ? RH8 users (RH
8 comes with 1.99.12) report the error:

TypeError: GtkTextBuffer.insert_at_cursor() takes exactly 2 arguments
(1 given)

but it works fine with 1 argument with 1.99.15.

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

You fill a much-needed gap.

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


Re: [pygtk] applets & libglade

2003-03-07 Thread Martin Preishuber
Hi,well actually the visibility behaviour of the GtkWindows changed
from glade1 to glade2 ... I just was used to use .Show() and was suprised,
that the windows are visibile per default now ... and late in the night, I
didn't think of such a simple thing like checking the visibility setting
:|Martin

- Original Message From:
"Christian Reis" <[EMAIL PROTECTED]>To: "Martin Preishuber"
<[EMAIL PROTECTED]>Cc: "Johan Dahlin"
<[EMAIL PROTECTED]>, [EMAIL PROTECTED]Subject: Re: [pygtk]
applets & libgladeDate: 06/03/03 14:07On Wed, Mar 05, 2003 at 11:57:24PM +0100, Martin Preishuber
wrote:> > > 2.) I create some windows with glade (pygtk2
1.99.15), to use it I do> > > something like:> >
>> > > xml = gtk.glade.XML(gladefile)> >
>> > > this works fine, but it immidiately shows the window
... is there any> > > way to load it invisible and set it to
visible manually later ? I need> > > to fill some parts of the
window before it is visible.> >> > Go into glade, mark
the window, go the Common tab, uncheck Visible.>> thanks again
... how comes, that I feel somehow stupid now ? :|You shouldn't.
This is a very common problem when using liglade to builda complex
application -- the parse of the file has the side-effect ofrendering the
window when it's marked as visible.I've discussed this before, and
I'm not sure there is a good solution tothe problem. On one hand, you
could ignore the visible attribute fortop-level windows, but that would
be violating the 1-1 correspondencebetween gladefile and libglade tree
which is expected. On the otherhand, you could have Glade make
GtkWindows not visible my default; butthen you have a consistency issue
between windows and other widgets.I don't see solutions (beyond
stuff likeGladeXML("foo.glade", invisible_windows=1)which I
don't like very much). But maybe somebody else does.Take
care,--Christian Reis, Senior Engineer, Async Open Source,
Brazil.http://async.com.br/~kiko/ | [+55 16] 261 2331 |
NMFL___pygtk mailing
list [EMAIL PROTECTED]http://www.daa.com.au/mailman/listinfo/pygtkRead the
PyGTK FAQ: http://www.async.com.br/faq/pygtk/

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


Re: [pygtk] Port of pugtk-1.99.15 on win32

2003-03-06 Thread Martin Preishuber
Hi,The page is nice yes :) the only thing which should be changed,
is the download site of GTK+ Runtime Environment. I think the primary site
ishttp://sourceforge.net/projects/gtk-win/since the
other site just references the sourceforge page. I wanted to change this in
Christians FAQ, but then I realized that I didn't have the password and
lazyness caught me :)Martin

- Original Message From:
"Christian Reis" <[EMAIL PROTECTED]>To: "Cedric Gustin"
<[EMAIL PROTECTED]>Cc: [EMAIL PROTECTED]Subject: Re:
[pygtk] Port of pugtk-1.99.15 on win32Date: 06/03/03 14:54On Wed, Mar 05, 2003 at 09:40:08PM +0100,
Cedric Gustin wrote:>> After some requests from a bunch of
users interested by my port of pygtk on> win32, I created a web page
with the binaries at>> http://www.pcpm.ucl.ac.be/~gustin/win32_ports/>>
Feel free to send any comment.Why not have a link to the older
versions, including the pygtk-0.6.xversions? You can put up a notice
saying "These are unsupported, use atyour own risk and don't dare
emailing me" if you don't want to behassled about it?Apart from
that, thanks for the webpage, it was really becomingnecessary
:-)Take care,--Christian Reis, Senior Engineer, Async Open
Source, Brazil.http://async.com.br/~kiko/ | [+55 16] 261 2331 |
NMFL___pygtk mailing
list [EMAIL PROTECTED]http://www.daa.com.au/mailman/listinfo/pygtkRead the
PyGTK FAQ: http://www.async.com.br/faq/pygtk/

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


Re: [pygtk] applets & libglade

2003-03-05 Thread Martin Preishuber
On Wed, 2003-03-05 at 23:29, Johan Dahlin wrote:
> ons 2003-03-05 klockan 19.24 skrev Martin Preishuber:
> > Hi,
> > 
> > just 2 short questions related to gnome-python2 (1.99.15)
> > 
> > 1.) I try to create a panel applet with
> > 
> > myapplet = gnome.applet.Applet()
> > 
> > and it just segfaults, is this the correct usage ?
> 
> Something like this:
> 
> def sample_factory(applet, iid):
> label = gtk.Label("Success!")
> applet.add(label)
> 
> applet.show_all()
> return gtk.TRUE
> 
> gnome.applet.bonobo_factory("OAFIID:GNOME_PythonAppletSample_Factory", 
>  gnome.applet.Applet.__gtype__, 
>  "hello", "0", sample_factory)

thanks :)

> > 2.) I create some windows with glade (pygtk2 1.99.15), to use it I do
> > something like:
> > 
> > xml = gtk.glade.XML(gladefile)
> > 
> > this works fine, but it immidiately shows the window ... is there any
> > way to load it invisible and set it to visible manually later ? I need
> > to fill some parts of the window before it is visible.
> 
> Go into glade, mark the window, go the Common tab, uncheck Visible.

thanks again ... how comes, that I feel somehow stupid now ? :|

Martin

-- 
Martin Preishuber <[EMAIL PROTECTED]>

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


[pygtk] applets & libglade

2003-03-05 Thread Martin Preishuber
Hi,

just 2 short questions related to gnome-python2 (1.99.15)

1.) I try to create a panel applet with

myapplet = gnome.applet.Applet()

and it just segfaults, is this the correct usage ?
2.) I create some windows with glade (pygtk2 1.99.15), to use it I do
something like:

xml = gtk.glade.XML(gladefile)

this works fine, but it immidiately shows the window ... is there any
way to load it invisible and set it to visible manually later ? I need
to fill some parts of the window before it is visible.

thanks,

Martin

-- 
Martin Preishuber <[EMAIL PROTECTED]>

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/


Re: [pygtk] gnome-python2 docs

2003-02-11 Thread Martin Preishuber
On Tue, 2003-02-11 at 22:24, Johan Dahlin wrote:
> tis 2003-02-11 klockan 19.05 skrev Martin Preishuber:
> > Hi all,
> > 
> > is there any documentation on gnome-python available ? I'm just porting
> > eroaster to gnome-python2 and I have some problems to get Gnome* widgets
> > working ... I can't find the UIITEM*, STOCK_MENU* constants,
> > GnomeQuestionDialog and so on ...
> 
> Sorry. As far as I know there is no documentation available for
> gnome-python.
> 
> Even the ones for C is not updated on the developer.gnome.org
> 
> But i know that UIITEM and STOCK_MENU is deprecated.
> 
> Use BonoboUI instead of UIITEM.
> Stock icons has moved to Gtk+ since 2.0

Hmm well ok then maybe someone can help me with the following code
fragments:

1.) I build menus with

self.filemenu = [ UIINFO_ITEM_STOCK(_('_New Project'), None,
self.ProjectNew, STOCK_MENU_NEW) ]
self.window.create_menus(self.menus)

where self.window has been a GnomeApp. Is that completely gone ?

2.) GnomeApp supported .add_toolbar ... anything similar now ?
3.) I used some GnomeEntry fields ... now the following code crashes:

>>> import gnome.ui
>>> entry = gnome.ui.Entry("")

(:1554): Gnome-CRITICAL **: file gnome-program.c: line 738
(gnome_program_get_app_id): assertion `program != NULL' failed
Segmentation fault

4.) Is there anything like GnomeErrorDialog, GnomeQuestionDialog in
gnome-python2 ?

thanks a lot ;-)

oh one more thing, what about compatibility between glade and glade2 ?
is it possible to use "old" glade files with gnome-python2 ?

Martin

-- 
Martin Preishuber <[EMAIL PROTECTED]>

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



[pygtk] gnome-python2 docs

2003-02-11 Thread Martin Preishuber
Hi all,

is there any documentation on gnome-python available ? I'm just porting
eroaster to gnome-python2 and I have some problems to get Gnome* widgets
working ... I can't find the UIITEM*, STOCK_MENU* constants,
GnomeQuestionDialog and so on ...

thanks,

Martin

-- 
Martin Preishuber <[EMAIL PROTECTED]>

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



Re: [pygtk] problem installing gnome.ui

2003-02-10 Thread Martin Preishuber
Hi John,

did you install pyorbit first ? I had the same problem yesterday and
noticed that I didn't install it. The message, that gnome.ui will be
built is wrong then.

Martin

On Mon, 2003-02-10 at 22:21, John Hunter wrote:
> I just compiled and installed pygtk and gnome-python 1.99.15 and
> cannot import gnome.ui
> 
> >>> import gnome
> >>> import gnome.ui
> Traceback (most recent call last):
> File "", line 1, in ?
> ImportError: No module named ui
> 
> My configure reported:
> 
> The following modules will be built:
> 
> gnome
> gnome.ui
> gnome.canvas
> gnome.vfs
> gconf
> bonobo
> bonobo.activation
> bonobo.ui
> gnome.applet
> nautilus
> 
> The following modules will NOT be built:
> 
> zvt
> gtkhtml2
> gnomeprint
> gnomeprint.ui
> 
> But ui does not appear to have been built in the gnome-python gnome
> subdir
> 
> video:/var/tmp/gnome-python-1.99.15> ls gnome/ui*
> gnome/ui.defs  gnome/ui.override  gnome/uimodule.c
> 
> The output of 'configure' and 'make' are available at:
> 
> http://nitace.bsd.uchicago.edu:8080/summer/jdh/make.out
> http://nitace.bsd.uchicago.edu:8080/summer/jdh/config.out
> 
> I have the same problem when I build with 'python setup.py build'.
> When I capture the output of the build, and then grep for 'building',
> I get
> 
> video:/var/tmp/gnome-python-1.99.15> grep building setup.py.out
> building 'gnome._gnome' extension
> building 'gnome.canvas' extension
> building 'gnome.vfs' extension
> building 'gnome.gconf' extension
> building 'gnome.applet' extension
> 
> Any suggestions? 
> 
> Thanks,
> John Hunter
> 
> Redhat Linux 8.0
> 
> video:~> gcc --version
> gcc (GCC) 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
> 
> video:~> python
> Python 2.2.1 (#1, Aug 30 2002, 12:15:30)
> [GCC 3.2 20020822 (Red Hat Linux Rawhide 3.2-4)] on linux2
> ___
> pygtk mailing list   [EMAIL PROTECTED]
> http://www.daa.com.au/mailman/listinfo/pygtk
> Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
-- 
Martin Preishuber <[EMAIL PROTECTED]>

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



Re: [pygtk] Porting applications from pygtk to pygtk2

2002-10-06 Thread Martin Preishuber

On Sat, 2002-10-05 at 18:06, Christian Reis wrote:
> On Sat, Oct 05, 2002 at 10:02:45AM +0200, Martin Preishuber wrote:
> > Since RedHat 8 includes pygtk2 and gnome-python2 per default now I get
> > some requests why my eroaster application doesn't work any more ... it
> > is a pygtk application ...
> 
> Blame RedHat for not having shipped the changes James and Johan worked
> on to allow coexistance of the modules, I'm afraid. I have no idea why
> they thought this was a good idea. 

damn ... actually I think it's probably a bit too early to generally
migrate because I don't know much about the status of other
distributions related to inclusion of pygtk2. The only thing I know is
that the unstable tree of debian contains pygtk and pygtk2, but not
python-gnome2, so I think it's too early for debian [actually I'm using
debian, eroaster uses python-gnome stuff so I would have to install
python-gnome2 manually ;-)]

> 
> > So is there a good clean way to port pygtk to pygtk2 applications ? How
> > much troubles will I have with changed widgets (eroaster includes many
> > different of them, pygtk and gnome-python ones) ? Is there any quick
> > documentation on porting available ?
> 
> Not really. I encourage you to:
> 
> a) Try the port. It shouldn't be too much work. Use gtk.py as a
> reference along with the docs.

I had a short look at it ... looks like the gtk  widgets are pretty
similar except of the Names ... I think this shouldn't be a problem.

> b) Update section 2 of the FAQ. :-)
> 
> > Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
> 

the FAQ is nice :) I just wondered, why some sections are missing (6 and
15 ;-))

thanks,

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

innovate, v.:
To annoy people.

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



[pygtk] Porting applications from pygtk to pygtk2

2002-10-05 Thread Martin Preishuber

Hi all,

Since RedHat 8 includes pygtk2 and gnome-python2 per default now I get
some requests why my eroaster application doesn't work any more ... it
is a pygtk application ...

So is there a good clean way to port pygtk to pygtk2 applications ? How
much troubles will I have with changed widgets (eroaster includes many
different of them, pygtk and gnome-python ones) ? Is there any quick
documentation on porting available ?

Thanks,

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

innovate, v.:
To annoy people.

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/



Re: [pygtk] Strange error.

2002-01-05 Thread Martin Preishuber

Hi,

Hehe, I'm the author of eroaster ;-) well pipes are always a bit
difficult to use with pygtk, you always get strange errors. There is a
native python implementation rmdir, if you need a recursive rm
implemented in python, the tools.py module of eroaster includes such a
function.

Martin

On Thu, 2002-01-03 at 12:37, Morelli Enrico wrote:
> Dear all,
> 
> I'm writing a tar, cdrecord, mkisofs front-end using PyGtk starting from
> eroaster program from sourceforge.
> I have to create a temporary directory to copy some data (no problem using
> os.mkdir), but if the directory exist, the program must remove it.
> During the execution I have the following error:
> 
> output=commands.getoutput('rm -rf %s' % self.CDR_multi)
>   File "/usr/lib/python1.5/commands.py", line 42, in getoutput
> return getstatusoutput(cmd)[1]
>   File "/usr/lib/python1.5/commands.py", line 52, in getstatusoutput
> text = pipe.read()
> IOError: [Errno 4] Interrupted system call
> 
> I have the same error if I use
> popen2.popen2('rm -rf %s' % self.CDR_multi).
> 
> 
> Some suggestion?
> 
> I use RH7.2 with python 1.5.
> -- 
>\\\ //
>(0 0)
> ooO-(_)-Ooo---
> ##=#
> | ENRICO MORELLI |  email: [EMAIL PROTECTED]   |
> | * *   *   *|  phone: +39 055 4574269 |
> |  University of Florence|  fax  : +39 055 4574253 |
> |  CERM - via Sacconi, 6 -  50019 Sesto Fiorentino (FI) - ITALY|
> ##=#
> 
> 
> ___
> pygtk mailing list   [EMAIL PROTECTED]
> http://www.daa.com.au/mailman/listinfo/pygtk
-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

"They that can give up essential liberty to obtain a little temporary
saftey deserve neither liberty not saftey."
-- Benjamin Franklin, 1759

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



[pygtk] python2, gtk 0.6.8 & GdkColor

2002-01-03 Thread Martin Preishuber

Hi all,

I try to change the background color and therefor I create a GdkColor
instance. With python 1.5 that works as expected, with python 2.1.1 I
get some errors when using parameters > 32767. Usually
GdkColor(65535, 65535, 65535) should be white so I can make any bright
colors with that restriction. The error I get is

return _gtk.gdk_color_new(red, green, blue, pixel)
OverflowError: signed short integer is greater than maximum

any ideas ?

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

Make a wish, it might come true.

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



[pygtk] pygnome-tools

2001-10-10 Thread Martin Preishuber

Hi there,

I've written some extended widgets for the gnome-python bindings. I
mainly use them in some of my tools, but I thought, that maybe someone
out there is interested in using it, too. The two main widgets are an
extended file selection dialog and a more informative progressbar.

Screenshots and Downloads are available at:

http://www.its4you.at/pygnome-tools.php
http://www.its4you.at/download.php?op=viewsdownload&sid=3

comments are welcome ;-)

Martin

-- 
Martin Preishuber - IT Expert, Student, SysAdmin
http://www.eclipt.at, mailto:[EMAIL PROTECTED]

I am NOT a nut

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



Re: [pygtk] D&D from KDE-apps

2001-01-25 Thread Martin Preishuber


On Thu, 25 Jan 2001, James Henstridge wrote:

> On Wed, 24 Jan 2001, Martin Preishuber wrote:
> 
> > Hi,
> > 
> > I've some problems with the D&D thingie ... I'm the author of ERoaster,
> > a GNOME-frontend for cdrecord & mkisofs. I've D&D support included,
> > which works fine for gmc, but not for other file-managers
> > (I'm thinking especially of konqueror). The code I use is basically
> > 
> > targets = [('text/plain', 0, 1),
> >('text/uri-list', 0, 2)]
> > 
> > files.connect("drag_data_received", self.DragDataReceive)
> > files.drag_dest_set(DEST_DEFAULT_ALL, targets, GDK.ACTION_COPY)
> > 
> > which is enough for getting the files in self.DragDataReceive
> > 
> > I tried DEST_DEFAULT_DROP but then I didn't get any response
> > (except of one avi file with gmc).
> 
> Do you know what types konquerer uses for its drags?  If you don't specify
> a type it uses, then the drag will not complete.

it uses 'text/uri-list' (at least that's what the author of ksysv told
me) ... but as far as I know, the target is only used if you use
DEST_DEFAULT_DROP ... it's not used with DEST_DEFAULT_ALL
I tried using DEST_DEFAULT_DROP but then I didn't get any drop events
at all (even if the icon wasn't a forbidden sign from konqueror any
more)

> Also make sure the app is a Qt >= 2.0 app, as earlier ones didn't use the
> XDnD protocol.

I use KDE 2.0.1 and QT 2.2.2

Martin



___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



[pygtk] D&D from KDE-apps

2001-01-24 Thread Martin Preishuber

Hi,

I've some problems with the D&D thingie ... I'm the author of ERoaster,
a GNOME-frontend for cdrecord & mkisofs. I've D&D support included,
which works fine for gmc, but not for other file-managers
(I'm thinking especially of konqueror). The code I use is basically

targets = [('text/plain', 0, 1),
   ('text/uri-list', 0, 2)]

files.connect("drag_data_received", self.DragDataReceive)
files.drag_dest_set(DEST_DEFAULT_ALL, targets, GDK.ACTION_COPY)

which is enough for getting the files in self.DragDataReceive

I tried DEST_DEFAULT_DROP but then I didn't get any response
(except of one avi file with gmc).

Any ideas ?

Martin



___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



[pygtk] Misc. Dummy User Questions

2000-07-29 Thread Martin Preishuber

Greetings,

since I found some time to work on my eroaster today, I also found some
things about the gnome-python-bindings I don't really understand, too:

- There are some conditions, where windows are not complettly drawn,
e.g.


while events_pending():
mainiteration()
system("sleep 5")

  even though the while-loop should make sure, everything should be on
the
  screen, in my case only the window frame is printed

- when setting a button inactive with
button.set_state(STATE_INSENSITIVE)
  I can't reactivate it any more (none of the other states worked)

- when creating a right justified label, e.g.

channel = GtkLabel("Channel: ")
channel.set_justify(JUSTIFY_RIGHT)
channel.show()

  and then attach it to a table column it will always be centered.

Thanks for any comments and help !

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Before I knew the best part of my life had come, it had gone.

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



[pygtk] D&D Bug (?) + get window position

2000-03-19 Thread Martin Preishuber

Hi all,

I'm currently having a GtkWindow(WINDOW_POPUP) which has drag and drop
connected
by using connect("drag_data_received", ...). works pretty fine, even
when
hiding and showing the window. when I change the window type to
WINDOW_DIALOG,
it works until I hide the window ... after doing a hide() and show() the
window doesn't get the d&d receive event any more, not even after
connecting
the event again.

some other question, is there any method to get the size & position of
a window ?

thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

"Remember, if it's being done correctly, here or abroad, it's ___not
the U.S.
Army doing it!"
-- Good Morning VietNam
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: pygnome 1.0.51 was Re: [pygtk] 2 Typos in gtk.py

2000-02-19 Thread Martin Preishuber

Hassan Aurag wrote:
> 
>  Btw,
> 
>  Any news of redhat rpms srpms for the new package?
> 
>  I think we should have a repository of srpms (no rpms needed since
> many arch's)
> kept up-to-date by rhlabs if possible?
> 
>  I really don't like to use tar.gz for file tracking reasons, like :
> what the heck is this file doing here? What does it do?
> 
>  Thanks

I always make rpms of current versions of pygtk/gnome-python ... you
can find it at

ftp://eclipt.uni-klu.ac.at/pub/people/mpreishu/

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

... I want to perform cranial activities with Tuesday Weld!!
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] 2 Typos in gtk.py

2000-02-19 Thread Martin Preishuber

Matt Wilson wrote:

> I don't see the problem in the latest release.  What are you looking
> at? 1.0.51?
> 
> Matt

hmmm line wrapping fault:

> > def get_hadjustment(self):
> > return GtkAdjusment(_obj=

 ^^ here's the t missing

> > def get_vadjustment(self):
> > return GtkAdjusment(_obj=
> >
 ^ and here

it's in 1.0.51 and in the cvs version

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

... I want to perform cranial activities with Tuesday Weld!!
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] 2 Typos in gtk.py

2000-02-19 Thread Martin Preishuber

Hi,

Still not knowing how to get the height of the title column of
the clist widget I'm playing around a lot and found 2 typos
in gtk.py (~line 1258, GtkCList):

def get_hadjustment(self):
return GtkAdjusment(_obj=
   
_gtk.gtk_clist_get_hadjustment(self._o))

 ^ should be GtkAdjustment (t is missing)

def get_vadjustment(self):
return GtkAdjusment(_obj=
   
_gtk.gtk_clist_get_vadjustment(self._o))

 ^ same here

btw. I'd still be happy if anyone could give me some idea 
for getting the column height of the title column ;-)

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

... I want to perform cranial activities with Tuesday Weld!!
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] get_selection_info next try

2000-02-16 Thread Martin Preishuber

Hi again,

So I just checked the source of gmc to check wether they do it. they
transform the y-koordinate the following way:

/* Normalize the y coordinate to the clist_window */

y -= (GTK_CONTAINER (clist)->border_width
  + clist->column_title_area.y
  + clist->column_title_area.height);

so how do I do the same with pygtk ?

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

We all live in a state of ambitious poverty.
-- Decimus Junius Juvenalis
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



get_selection_info (was Re: [pygtk] bounced message)

2000-02-16 Thread Martin Preishuber

> The problem appears to be that get_selection_info expects coordinates
> relative to the top left of the window holding the rows, while the
> coordinates passed to your dragreceivelist method are relative to the
> top left of the widget.  In your example this causes the row results to
> be one greater than expected, and the last row to be ignored
> completely.  (Actually, since the title is slightly taller than a normal
> row you get different results depending on whether you end the drag at
> the top or bottom of a row.)  If you put the GtkCList object inside a
> scrolled window and add a large number of rows this mismatch is even
> more pronounced - anything occupying the topmost (row height + cell
> spacing) pixels will always be reported as row 0, regardless of how far
> down you scroll.

Hmmm not sure wether this is true ... slightly modified the example
program to check that behaviour (added a dummy label on top and inserted
100 rows). so the problem is the Label of the CList. It works fine, if
there's no label (including scrolling ... at least I get the right
results) ... but as soon as I enable the Label of the CList, the results
are wrong.
 
> The solution is either to translate the coordinates into the the
> required format or to obtain the pointer position by some other suitable
> method once dragreceivelist is called.  A brief look through the GTK
> reference pages didn't yield any obvious clues as to how to do either,
> so perhaps someone else can help here?

I think the solution is to manually subtract the height of the label
when
enabled ... gonna check wether that's somehow possible.

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

We all live in a state of ambitious poverty.
-- Decimus Junius Juvenalis
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] GtkCList/CTree get_selection_info

2000-02-14 Thread Martin Preishuber

Hi again,

I've made a simple example which shows the unwanted behaviour mentioned
earlier ... could someone test it and post his/her results ? For me
when dragging something to the list it returns (0,0) for the label,
(1,0) for "First" and None for "Last"

thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

As for the women, though we scorn and flout 'em,
We may live with, but cannot live without 'em.
-- Frederic Reynolds

#!/usr/bin/python

from gtk import *

class clisttest:

def destroy(self, args):
self.win.destroy()
mainquit()

def __init__(self):
self.win = GtkWindow()
self.win.show()
self.win.connect("destroy", self.destroy)

targets = [('text/plain', 0, -1)]
list = GtkCList(1, ["Label"])
list.append(["first"])
list.append(["second"])
list.append(["last"])
list.connect("drag_data_received", self.dragreceivelist)
list.drag_dest_set(DEST_DEFAULT_ALL, targets, GDK.ACTION_COPY)
list.show()

swin = GtkScrolledWindow()
swin.set_policy(POLICY_AUTOMATIC, POLICY_AUTOMATIC)
swin.add(list)
swin.show()

self.win.add(swin)
self.win.show()

def dragreceivelist(self, clist, context, x, y, data, info, time):
selection = clist.get_selection_info(x, y)
print selection

def main(self):
mainloop()

app = clisttest()
app.main()



Re: [pygtk] GtkCList/CTree get_selection_info

2000-02-14 Thread Martin Preishuber

James Henstridge wrote:

> The function should be returning None if you click outside of the cells,
> or (row,col) if you click on a cell.  I don't know why it would be acting
> differently on your system.

I know what it should do ... but it doesn't ... maybe there's something
wrong with the (x,y) pair ... it definitely doesn't do what it should do
here :(



> This is a pretty close match to the documented behaviour of the function:
>   http://developer.gnome.org/doc/API/gtk/gtkclist.html#GTK-CLIST-GET-SELECTION-INFO

You could check wether it behaves correct on your computer ... the
program
is ECLiPt SSH Shell, the "buggy" version can be found at

ftp://eclipt.uni-klu.ac.at/pub/projects/e-ssh-sh/beta/

the behaviour happens, when you d&d a file to a ssh connection

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

As for the women, though we scorn and flout 'em,
We may live with, but cannot live without 'em.
-- Frederic Reynolds
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] GtkCList/CTree get_selection_info

2000-02-14 Thread Martin Preishuber

Hi,

just playing with drag and drop to CLists and CTrees and there's some
strange thing. I've done something like:

list.connect("drag_data_received", DragReceiveList)

def DragReceiveList(clist, context, x, y, data, info, time):
selection = clist.get_selection_info(x, y)

so this should return row,col of the current selection. The bad
thing is, that it returns (0,x) for the title of the clist,
(1,x) for the first element of the clist and None for the last
element, which is wrong IMHO.

any ideas ?

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The luck that is ordained for you will be coveted by others.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] Disable buttons & keyboard shortcuts

2000-01-24 Thread Martin Preishuber

Hi list,

2 simple questions:

- How can I disable/enable buttons (GtkButton)?
- How can I add keyboard shortcuts to menu entries, e.g. to

filemenu = [ UIINFO_ITEM_STOCK('Quit', None, self.Destroy,
STOCK_MENU_QUIT),]
menus = [ UIINFO_SUBTREE('File', self.filemenu),]
window.create_menus(menus)

  something like ctrl-q to the Quit menu

Thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Lend money to a bad debtor and he will hate you.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] GDK Bindings ?

2000-01-22 Thread Martin Preishuber

Hi there,

are there any of the bindings for gdk* functions (e.g. 
gdk_screen_width or gdk_window_get_pointer) ?
or alternatively, has anyone some idea to realize this problem:
I have some gnome-applet and want to open a popup window, where
the window should appear just over the icon in the panel.

Thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

It's OKAY -- I'm an INTELLECTUAL, too.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] How do I build from cvs sources?

2000-01-20 Thread Martin Preishuber

John Ehresman wrote:
> 
> Hi,
> 
> I'm trying to build from the cvs sources from the gnome cvs server in
> order to test Matt's many fixes (thanks!).  I've checked out the sources
> and realized that I need a patched version of automake, so I went to
> Cygnus's site and grabbed the cvs version of automake and installed it.
> But, automake still emits warnings about bad macros and invalid variables
> and doesn't produce a Makefile.
> 
> Do I need to apply different patches to automake?  Is there an easier way
> to do this? I'm running on an intel RedHat 6.1 system.
> 
> Thanks,

Hi,

Ok do the following: first get the python-devel RPM and install it.
I've made a patched version of automake which includes the necessary
patches:

http://daddy.stuco.uni-klu.ac.at/automake-1.4-py1.src.rpm
http://daddy.stuco.uni-klu.ac.at/automake-1.4-py1.noarch.rpm

Install it ;-) Then you need the .m4 file of gtkglarea (here we go:

http://daddy.stuco.uni-klu.ac.at/gtkgl.m4

copy it to /usr/share/aclocal

Then you're ready to build gnome-python ... type 

autogen.sh --prefix=/usr
make
make install

This should do it (on a redhat 6.1 machine)

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The race is not always to the swift, nor the battle to the strong, but
that's the way to bet.
-- Damon Runyon
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] GTK warning in CVS version

2000-01-20 Thread Martin Preishuber

Hi again,

I've just build the current CVS version of gnome-python ... works
fine, except that everytime I quit any program I get some GTK warning:

Gtk-WARNING **: invalid cast from `(unknown)' to `GnomeClient'

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The race is not always to the swift, nor the battle to the strong, but
that's the way to bet.
-- Damon Runyon
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] typo in gtk.py

2000-01-20 Thread Martin Preishuber

Hi,

just found some typo in gtk.py (lines 1220--1221):

def row_move(self, soure_row, dest_row):
   ^ should be source_row
_gtk.gtk_clist_row_move(self._o, source_row, dest_row)

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The race is not always to the swift, nor the battle to the strong, but
that's the way to bet.
-- Damon Runyon
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] Documentation

2000-01-19 Thread Martin Preishuber

Hassan Aurag wrote:



>  -The pygtk/pygnome example code by James Henstridge. They really are excellent
> and simple to read.

true



Some other documentation is http://www.gtk.org/tutorial/ which is not
for
python, but a good and clean list of widgets and that stuff ... the
commands
are nearly the same in python.

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Velilind's Laws of Experimentation:
(1) If reproducibility may be a problem, conduct the test only once.
(2) If a straight line fit is required, obtain only two data points.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] gnome-python / signal / fork

2000-01-12 Thread Martin Preishuber

Hi all,

Got some question concerning fork and signal in gnome-python
applications:
is there anything special which should be considered ? I made some app
which installs a sigchld handler and does some forking:

def SigChldHandler(signal_number, stack_frame):
signal.signal(signal.SIGCHLD, SigChldHandler)
result = os.wait()

class Application:
def __init__(self):
signal.signal(signal.SIGCHLD, SigChldHandler)
def run(self, args):
result = os.fork()
if (result == 0):
os.execv("/usr/bin/env", ["/usr/bin/env", command])

so the problem with that code is, that the sigchldhandler is
executed when the next program is started / forked ... that means
that there are always some zombie processes around ... any
idea someone ?

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Wernher von Braun settled for a V-2 when he coulda had a V-8.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] Properties of ZvtTerm()

1999-02-27 Thread Martin Preishuber

Hi,

Another question: is it possible to change the properties 
(foreground,background)-color of a ZvtTerm() ? I've tried to
use a rc file but I don't know the Gtk* name of it ...
plus term.set_color_scheme() need 16 (!) color tuples,
and I don't want to specify all of it.

thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Q:  Why did the astrophysicist order three hamburgers?
A:  Because he was hungry.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] ToggleButton (set_state)

1999-02-27 Thread Martin Preishuber

Hi,

Just a quick question, has set_state of toggle buttons changed
somewhen ? when I do something like button.set_state(1) it doesn't
seem to work any more ...

Martin

-- 
Martin Preishuber - Student, ECLiPt Core Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

My interest is in the future because I am going to spend the rest of my
life there.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] new release of pygtk and gnome-python

1998-12-21 Thread Martin Preishuber

Hi,

actually I think it would be a good idea to keep in sync with the
versions on the ftp.gnome.org site ... the current versions there are
0.99 for gnome and 1.1.7 for glib/gtk ... gnome-python 0.90 doesn't work
with those versions :(

Martin

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

I joined scientology at a garage sale!!
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] gnome-python which version ?

1998-12-19 Thread Martin Preishuber

Hi there,

I've installed the current gnome rpms (gnome 0.99, glib/gtk 1.1.7) ...
the
pygtk version on james's ftpsite worked fine, the python-gnome snapshot
didn't
so I downloaded the cvs version, which compiled, but I get some error
with
the apps:

Traceback (innermost last):
  File "/usr/local/bin/eroaster", line 7, in ?
from Gtkinter import *
  File "/usr/lib/python1.5/site-packages/Gtkinter.py", line 6, in ?
from gtk import *
  File "/usr/lib/python1.5/site-packages/gtk.py", line 21, in ?
import _gtk
ImportError: /usr/lib/python1.5/site-packages/_gtkmodule.so: undefined
symbol: gtk_widget_set_app_paintable

any ideas ?

Martin

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

O.K., fine.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] Entry Field Size and Program Output

1998-11-30 Thread Martin Preishuber

Richard Fish wrote:

> I use code something like this to create, for example, a GtkEntry that
> will hold 10 characters:
> 
>   length=10
>   e=GtkEntry()
>   e.set_max_length(length)
>   e.set_usize((length+2)*9,-1)
> 
> The formula in set_usize I got by trial and error, using the default
> font.  I'm not sure how to do this in a non-font-specific manner.

oh fine, that will do it ;-)

> You want select() -- search the Python library reference...

actually there's a more comfortable solution for that ... I use
something like
this now:

pipe = popen(command, "r")

self.gtag = input_add(pipe, GDK.INPUT_READ, self.ReadOutput)

def ReadOutput(self, pipe, readwrite):
line = pipe.readline()
if (line == ""):
pipe.close()
input_remove(self.gtag)
else:
self.output.insert_defaults(line)

There is some problem with buffering, but that's not too bad :)

> Some programs do this with backspaces, others with carriage returns.
> Some use real terminal addressing.  In the first two cases, you've got a
> chance.  I don't know how you would handle the terminal addressing case
> though...

 

I'm gonna try that piece of code, thanks a lot !
James said something about some terminal emulation thingie in the gnome
wrapper, maybe this can handle all cases :)

Thanks for your help !

Martin

> --
> Richard Fish  Enhanced Software Technologies, Inc.
> Software Developer4014 E Broadway Rd Suite 405
> [EMAIL PROTECTED]Phoenix, AZ  85040
> (602) 470-1115http://www.estinc.com
> To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]

Interesting company :) I've been trying bru2000 once (the version which
has been
shipped with RedHat 5.1), but I didn't get it to work within a minute,
so I 
didn't mess around with it any longer (I don't really need backup
software for
my old 400MB streamer ;-))

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

Gravity:
What you get when you eat too much and too fast.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



Re: [pygtk] PyGTK / GTK ? Problem

1998-11-30 Thread Martin Preishuber

Re,

> Surely you must be able to fork in a GTK program, since this is used in
> the GNOME libraries for things like scores, program loading and other
> things (the best example being the panel, where fork'ing and exec'ing are
> its main job.

ok, fine

> Do you know which process is dieing?  Also, what happens if you run your
> script like this:
> 
>   $ gdb python
>   (gdb copyright message)
>   gdb> run scriptname.py
> 
> Which of the two processes dies?  If the main process dies, could you try
> doing a backtrace (with the bt command under gdb), and see if it gives any
> clues.

I've attached the test script I'm using (fork.py):

- The script works without the "import gtk" line
- Including the "import gtk" line I get the following error:

Gdk-Message: locale not supported by C library
parentpid: 4348
childpid: 4349
Gdk-Message: 
** ERROR **: sigpipe caught

- Running it through gdb:

(gdb) run fork.py
Starting program: /usr/local/bin/python fork.py
Gdk-Message: locale not supported by C library
childpid: 4354
parentpid: 4351

Program received signal SIGPIPE, Broken pipe.
0x40096744 in __write ()
(gdb) info program
Using the running image of child Pid 4351.
Program stopped at 0x40096744.
It stopped with signal SIGPIPE, Broken pipe.
(gdb) bt
#0  0x40096744 in __write ()
#1  0x402f8c84 in __DTOR_END__ ()
#2  0x402aace9 in _X11TransWrite ()
#3  0x40291cd8 in _XFlushInt ()
#4  0x40292fe2 in _XReply ()
#5  0x4028f129 in XSync ()
#6  0x40278bd9 in XCloseDisplay ()
#7  0x4021c586 in gdk_exit_func () at gdk.c:3048
#8  0x4004a6f5 in exit (status=0) at exit.c:55

Hope this helps somehow ...

Martin

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The difference between legal separation and divorce is that legal
separation gives the man time to hide his money.

#!/usr/local/bin/python
import gtk
import os
import sys

result = os.fork()

def child():
print "childpid: " + str(os.getpid())
sys.exit()

def parent():
print "parentpid: " + str(os.getpid())

if (result == 0):
child()
else:
parent()
os.waitpid(result, 0)




Re: [pygtk] PyGTK / GTK ? Problem

1998-11-30 Thread Martin Preishuber

James Henstridge wrote:
 
> That is wierd.  When you import GTK, it creates a connection to the X
> server.  I guess when the fork occurs, both programs have fd's for the
> same connection to the X server.

understandable ...

> Do you get the same error if you perform the fork before importing gtk?

it just happens when I import gtk.

does that mean, I can't fork within any python script which uses gtk ?

Martin

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

The difference between legal separation and divorce is that legal
separation gives the man time to hide his money.
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]



[pygtk] PyGTK / GTK ? Problem

1998-11-29 Thread Martin Preishuber

Hi all,

Can anyone run this little program:

#!/usr/local/bin/python
import gtk
import os
import sys
if os.fork():
print "hello"
sys.exit()
else:
print "main"

and tell me what's wrong with that ? when I start it I get something
like:

hello
main
[preisl@bofh ~/Software/ERoaster]$ 
Gdk-ERROR **: BadGC (invalid GC parameter)
  serial 33 error_code 13 request_code 60 minor_code 0

aborting...

Thanks,

Martin

-- 
Martin Preishuber - Student, ECLiPt Member, SysAdmin
http://eclipt.uni-klu.ac.at,
mailto:[EMAIL PROTECTED]

I always say beauty is only sin deep.
-- Saki, "Reginald's Choir Treat"
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]