| Author |
Message |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Wed 29 Jun 2011, 21:02 Post subject:
|
|
I had downloaded and compiled the source on June 27th at 9:37 am.
I had no problems with the close or exit buttons in programs.
What programs did you use for reference to verify this?
|
|
Back to top
|
|
 |
smokey01

Joined: 30 Dec 2006 Posts: 1602 Location: South Australia
|
Posted: Thu 30 Jun 2011, 06:12 Post subject:
|
|
It was only the button in partview. The other apps I tested, the close button seem to work ok.
I think the problem is with partview not gtkdialog.
_________________ Puppy Software <-> Distros <-> Puppy Linux Tips
|
|
Back to top
|
|
 |
pemasu

Joined: 08 Jul 2009 Posts: 5165 Location: Finland
|
Posted: Thu 30 Jun 2011, 08:02 Post subject:
|
|
I was sure I got nonworking quit button with some other gtkdialog application also. I recompiled the latest gtkdialog again. I cant reproduce the problem with any other than Partview, all the other apps I tested works as it should. Reverting back to the Patriots gtkdialog version restores the Partview Quit button usage.
Sorry, it seems there is so far only Partview in my Puppies which does not work as it should.
I have used in woof partview-2.1.pet. It is from quirky repo.
http://distro.ibiblio.org/quirky/pet_packages-quirky/partview-2.1.pet
|
|
Back to top
|
|
 |
thunor

Joined: 14 Oct 2010 Posts: 342 Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
|
Posted: Thu 30 Jun 2011, 18:25 Post subject:
|
|
| pemasu wrote: | I was sure I got nonworking quit button with some other gtkdialog application also. I recompiled the latest gtkdialog again. I cant reproduce the problem with any other than Partview, all the other apps I tested works as it should. Reverting back to the Patriots gtkdialog version restores the Partview Quit button usage.
Sorry, it seems there is so far only Partview in my Puppies which does not work as it should.
I have used in woof partview-2.1.pet. It is from quirky repo.
http://distro.ibiblio.org/quirky/pet_packages-quirky/partview-2.1.pet |
Hi pemasu
I was intrigued so I took a look. /usr/sbin/partview uses a perl script to create /tmp/partview.glade which is passed to gtkdialog3.
Yes it quits using the gtkdialog3 binary that came with my lupu 520, but I compiled gtkdialog3-0.7.20-pe-1, edited /usr/sbin/partview to use that instead and I experienced the same problem. There's a message in the terminal which will help to resolve it:
| Code: |
** (gtkdialog:8741): CRITICAL **: on_any_button_clicked: assertion `command != NULL' failed
|
Ok, I found bugs in glade_support.c which have always been there, the same bug in 3 functions. The functions should have been checking that "full_command" (the string passed in) was not NULL but were instead checking that a newly allocated uninitialised local pointer called "command" was not NULL I've fixed them but I'm not committing until tomorrow as I have a huge amount of new code to check before I do
Regards,
Thunor
|
|
Back to top
|
|
 |
zigbert

Joined: 29 Mar 2006 Posts: 5240 Location: Valåmoen, Norway
|
Posted: Thu 30 Jun 2011, 18:34 Post subject:
|
|
| thunor wrote: | I've fixed them but I'm not committing until tomorrow as I have a huge amount of new code to check before I do  | You are just wonderful!
_________________ Stardust resources
|
|
Back to top
|
|
 |
pemasu

Joined: 08 Jul 2009 Posts: 5165 Location: Finland
|
Posted: Fri 01 Jul 2011, 02:45 Post subject:
|
|
Thunor. Thank you of your quick testing, fix and report. I will retest new gtkdialog3 when it is time and will include it to the next version of my puppy. It seems nice way to find some problems and it will benefit all to get them hunted.
|
|
Back to top
|
|
 |
01micko

Joined: 11 Oct 2008 Posts: 7017 Location: qld
|
Posted: Fri 01 Jul 2011, 02:49 Post subject:
|
|
Funny that glade bug is not apparent in spup. Anyway, new spup will be soon and I'll include the latest gtkdialog revision too (and perhaps some other gtkdialog goodies )
_________________ keep the faith .. 
|
|
Back to top
|
|
 |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Tue 26 Jul 2011, 00:50 Post subject:
|
|
I have been playing with the child window that patriot so kindly made work.
I found that by including a text area with a variable for the child process, I could add a child that was a lot more than just a text box.
I then proceeded to add another child process to see if more than one was supported.
It is. But it is a one way thing. The first child process in the script must be launched first or the script will crash.
But after starting both child processes, either can be closed from the main dialog.
It was an interesting experience though.
And for the curious, I actually used one of the gtkdialog examples of tree stock icons as a child process.
Also, the example in usr/share/doc/gtkdialog3/examples/01.02-button_action_types needs the addition of a variable statement to work correctly as to closing the child from the child window.
|
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 1360 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Sun 31 Jul 2011, 06:10 Post subject:
|
|
Hello,
Thank a lot to zigbert for GtkDialog tips which are so clever and... useful!
Question:
In the script showing how to move items in list by drag'n drop...
| Code: | #!/bin/sh
move (){
PRESS_EVENT="`cat /tmp/PRESS_EVENT`"
grep -Fv "$PRESS_EVENT" /tmp/list > /tmp/tmp
grep -Fm1 -B500 "$TREE" /tmp/tmp | grep -v "$TREE" > /tmp/tmp1
echo "$PRESS_EVENT" >> /tmp/tmp1
grep -Fm1 -A500 "$TREE" /tmp/tmp >> /tmp/tmp1
mv -f /tmp/tmp1 /tmp/list
}
export -f move
ls -1 /usr/share/backgrounds > /tmp/list
export test="
<tree rules_hint=\"true\" hover-selection=\"true\" tooltip-text=\"Drag'n drop items to move them in list\">
<label>Backgrounds</label>
<input>cat /tmp/list</input>
<variable>TREE</variable>
<height>300</height><width>200</width>
<action signal=\"button-press-event\">echo \$TREE > /tmp/PRESS_EVENT</action>
<action signal=\"button-release-event\">move</action>
<action signal=\"button-release-event\">refresh:TREE</action>
</tree>"
gtkdialog3 --center -p test |
... I noticed annoying behavior:
When user just clicks any item of the list without dragging it (this may happen!), the list disappears and let just the clicked item inside... Have somebody got any idea about the way to prevent this?
Thanks you a lot for your attention.
Cordialement!
_________________

|
|
Back to top
|
|
 |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Sun 31 Jul 2011, 15:16 Post subject:
|
|
I am not sure how one could code it, but it seems that the button-release-event that calls the move function is not at fault.
Instead, the button-press-event would call another function to note the cursor position in a variable and then the move function would check that variable for a change of cursor position.
If it was the same, the move would be aborted.
|
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 1360 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Mon 01 Aug 2011, 05:13 Post subject:
|
|
Hello 8-bit,
Thanks for your reply.
| Quote: | | Instead, the button-press-event would call another function to note the cursor position in a variable and then the move function would check that variable for a change of cursor position. | This is probably one of the solutions! Please, may I ask you to tell more about or give any link where I could find example or explanations?
Cordialement.
_________________

|
|
Back to top
|
|
 |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Tue 02 Aug 2011, 16:22 Post subject:
|
|
Argolance nad others,
If you want to see my solution to the drag example list disappearing, go
HERE.
It may not be the best, but it works.
And by the way, I found all I needed on this forum!
|
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 1360 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Wed 03 Aug 2011, 14:07 Post subject:
|
|
Thank you a lot!
_________________

|
|
Back to top
|
|
 |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Wed 03 Aug 2011, 16:13 Post subject:
Subject description: gtkdialog reserved words list needed |
|
When one is writing a gtkdialog script, there seems to be no reference one can refer to as to words that are reserved for gtkdialog.
A list of those words would be nice so one knows not to use them as variables or other areas where they might conflict with reserved words.
Good idea or bad?
|
|
Back to top
|
|
 |
Dave_G

Joined: 21 Jul 2011 Posts: 459
|
Posted: Wed 03 Aug 2011, 17:15 Post subject:
|
|
I've just started coding with gtkdialog and have to agree 100% with 8-bit.
Unfortunately this lack of documentation is not unique to gtkdialog, it seems
to be pretty common in the Linux world.
A very big stumbling block for newbies like myself.
Dave.
|
|
Back to top
|
|
 |
|