Re: how to use simple-dialog in widget-dialog.jl



>> >> Oh, this seems too complicated. If I need a bash script and some more
>> >> magic, I'd rather use zenity. It's very simple to create dialogs from
>> >> zenity from a bash script and this would work very well, but would
>> >> introduce zenity dependence into my sawfish kit. So, if possible, I'd
>> >> like to use a lisp solution from sawfish only.
>> >
>> > Sawfish can do it (more precisely, librep + rep-gtk), but currently
>> > none has done it. Practically it's not a bad idea at all to use other
>> > programs. If I remember correctly gxmessage is a dialox box and can
>> > exectute program at button press, too.
>> >
>> > I use similar one, hand-written by me. When I try to exit Sawfish, but
>> > some windows are open, then it asks confirmation, excluding
>> > sawfish-pager and so on.
>>
>> Okay, thanks, I'll go with an external shell script too, then.
>>
>> > I'll send later on how to control Sawfish from shell.
>> >
>> >>> If you know the basics of gtk, then it's not so difficult to creat a
>> >>> dialog box. Have a look at examples/ in rep-gtk. (Bah, gtk-dialog.jl
>> >>> breaks your Sawfish session.
>> >>
>> >> What do you mean by 'breaks your sawfish session'?
>> >
>> > Literally. If you execute the script, not immediately, but seemingly
>> > when you do a window operation, Sawfish crashes.
>> >
>> > From rep-gtk/README:
>> > ------------------------------------------------------------------------
>> > Caveats
>> > =======
>> >
>> > It's still too easy to crash the Lisp interpreter through invalid use
>> > of GTK..
>> > ------------------------------------------------------------------------
>> >
>> > ;)
>>
>> Thanks! This helps, I've seen this behavior, sawfish crashing
>> unexpectedly after poking around with librep + rep-gtk, but didn't
>> know it's related.
>>
>> Cheers,
>> Daniel
>
> This should not happen, if you start a new rep interpreter instead of using
> sawfish-client (in most cases).

To be honest I don't really know what caused the crash and the reason
is that I'm not very familiar with lisp in general and rep/rep-gtk in
particular. I was just poking around in an unreproducable way. Anyway,
now I just call a shell script from my root menu for poweroff and this
shell script is simply

#!/bin/bash

zenity --question --text="Really power off?"
if [ $? -eq 0 ] ; then
    poweroff
fi

and this works very well.

Cheers,
Daniel

-- 
Psss, psss, put it down! - http://www.cafepress.com/putitdown


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]