Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 02 Oct 2014, 13:01
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
GtkDialog - tips
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 32 of 64 Posts_count   Goto page: Previous 1, 2, 3, ..., 30, 31, 32, 33, 34, ..., 62, 63, 64 Next
Author Message
disciple

Joined: 20 May 2006
Posts: 6439
Location: Auckland, New Zealand

PostPosted: Sun 05 Jun 2011, 20:01    Post_subject:  

Yes, we should do that. But not sourceforge - it always seems to be slow and unreliable for me.
What does anyone else think?
I have a project on google code and I think it is faster and more reliable. But it is also rather stupid in some ways...

_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send_private_message 
abushcrafter


Joined: 30 Oct 2009
Posts: 1447
Location: England

PostPosted: Mon 06 Jun 2011, 11:29    Post_subject:  

disciple wrote:
What does anyone else think?

http://savannah.gnu.org/
http://gna.org/
http://puszcza.gnu.org.ua/

_________________
adobe flash is rubbish!
My Quote:"Humans are stupid, though some are clever but stupid." http://www.dependent.de/media/audio/mp3/System_Syn_Heres_to_You.zip http://www.systemsyn.com/
Back to top
View user's profile Send_private_message Visit_website 
thunor


Joined: 14 Oct 2010
Posts: 350
Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings

PostPosted: Mon 06 Jun 2011, 12:29    Post_subject:  

http://en.wikipedia.org/wiki/Comparison_of_open_source_software_hosting_facilities

I looked at Google Project Hosting and it appears to tick the necessary boxes. It supports a wiki which would certainly make maintaining the documentation easier and more fun.

I sent the Gtkdialog author an email and he stated that he doesn't have time for the project anymore but would be happy for development to continue, so you can register "gtkdialog" as the project name Smile
Back to top
View user's profile Send_private_message Visit_website 
disciple

Joined: 20 May 2006
Posts: 6439
Location: Auckland, New Zealand

PostPosted: Mon 06 Jun 2011, 21:08    Post_subject:  

abushcrafter wrote:
disciple wrote:
What does anyone else think?

http://savannah.gnu.org/
http://gna.org/
http://puszcza.gnu.org.ua/

Yes, but do you have any feedback on what they are like to use.

e.g. Sourceforge seems to be slow and unreliable (for me).

Google code is not... but they seem to lack attention to detail. There is a list of little bugs as long as your arm.
e.g. you can't save the "source" settings page without entering a path for branches (which IIRC means that your repository must already include the folder to enter the path to... but what if you don't want branches?), and if you don't save the "source" settings page then it displays the wrong url for users to checkout the code... and IIRC it doesn't even tell you that the page did not save, and why. Perhaps that is why projects often display the wrong url Rolling Eyes

Also, presumably people would be happy with svn, rather than something more advanced like Git? Personally I think svn will be fine, as I doubt there will be a huge amount of activity.

_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send_private_message 
zigbert


Joined: 29 Mar 2006
Posts: 5729
Location: Valåmoen, Norway

PostPosted: Tue 07 Jun 2011, 16:37    Post_subject:  

Wonderful !!!

My coding-fingers are trembling when hearing about dynamic pixmap rendering Very Happy
I hope we get a pet with all patches.

The latest gtkdialog with patriots patches can be found here

- Moose On The Loose offered a fix here
- thunors very exiting patch is here


Barry's blog
http://bkhome.org/blog/?viewDetailed=01264
http://bkhome.org/blog/?viewDetailed=01279


Sigmund

_________________
Stardust resources
Back to top
View user's profile Send_private_message Visit_website 
BarryK
Puppy Master


Joined: 09 May 2005
Posts: 7047
Location: Perth, Western Australia

PostPosted: Tue 07 Jun 2011, 21:39    Post_subject:  

zigbert wrote:
Wonderful !!!

My coding-fingers are trembling when hearing about dynamic pixmap rendering Very Happy
I hope we get a pet with all patches.

The latest gtkdialog with patriots patches can be found here

- Moose On The Loose offered a fix here
- thunors very exiting patch is here


Barry's blog
http://bkhome.org/blog/?viewDetailed=01264
http://bkhome.org/blog/?viewDetailed=01279


Sigmund


Great, I have downloaded those patches and put it in my todo list to upgrade gtkdialog3 pet soon.

_________________
http://bkhome.org/news/
Back to top
View user's profile Send_private_message Visit_website 
zigbert


Joined: 29 Mar 2006
Posts: 5729
Location: Valåmoen, Norway

PostPosted: Wed 08 Jun 2011, 00:52    Post_subject:  

BarryK wrote:
Great, I have downloaded those patches and put it in my todo list to upgrade gtkdialog3 pet soon.
Mmmmmmmm


Thank you
Sigmund

_________________
Stardust resources
Back to top
View user's profile Send_private_message Visit_website 
01micko


Joined: 11 Oct 2008
Posts: 7805
Location: qld

PostPosted: Wed 08 Jun 2011, 01:19    Post_subject:  

Hehe.. I made a clunky wall setter with preview awhile ago.. it's tiny, ugly and clunky but it works. Maybe with this newfound functionality we could have a nice wallpaper setter with all the features from Nathan's plus preview...
sws-0.2.pet
Description 
pet

 Download 
Filename  sws-0.2.pet 
Filesize  4.08 KB 
Downloaded  221 Time(s) 
sws.jpg
 Description   
 Filesize   35.59 KB
 Viewed   1203 Time(s)

sws.jpg


_________________
Woof Mailing List | keep the faith Cool |
Back to top
View user's profile Send_private_message Visit_website 
thunor


Joined: 14 Oct 2010
Posts: 350
Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings

PostPosted: Wed 08 Jun 2011, 09:11    Post_subject:  

I've been playing some more and I've found a bug in gtkdialog-0.7.20 which causes a segfault if a declared pixmap doesn't physically exist. This segfault doesn't happen in gtkdialog3 but since a pointer to a null string should be being returned when nothing is being returned, it could simply be luck.

[EDIT] 20110618-22:01 Gtkdialog is now in a repository (see this post).

find_pixmap is the function that calls locate which causes the "sh: locate: command not found" command-line message. The problem with this function is that for me -- if I declare a non-existent image file -- I am falling through the bottom of it and there's a missing return ""; which happens to be very important. If you add this to the bottom of the function then it doesn't segfault. Additionally I've noticed that a gtk stock broken image icon now appears which either I haven't noticed before or is a consequence of my new code.

Edited_times_total
Back to top
View user's profile Send_private_message Visit_website 
Dougal


Joined: 19 Oct 2005
Posts: 2505
Location: Hell more grotesque than any medieval woodcut

PostPosted: Wed 08 Jun 2011, 15:00    Post_subject:  

thunor wrote:
find_pixmap is the function that calls locate which causes the "sh: locate: command not found" command-line message. The problem with this function is that for me -- if I declare a non-existent image file -- I am falling through the bottom of it and there's a missing return ""; which happens to be very important.

Might as well get rid of all that locate crap... Puppy doesn't use it.

_________________
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind
Back to top
View user's profile Send_private_message 
thunor


Joined: 14 Oct 2010
Posts: 350
Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings

PostPosted: Wed 08 Jun 2011, 19:01    Post_subject:  

Dougal wrote:
Might as well get rid of all that locate crap... Puppy doesn't use it.

I agree. find_pixmap is called from src/automaton.c in two places and simply tests that the file can be read, if not attempts to open it in /usr/share/icons/Bluecurve/16x16/stock/, if not tries locate before finally returning "".

Here's some code to refresh button pixmaps:

[EDIT] 20110618-22:01 Gtkdialog is now in a repository (see this post).

Added button widget image refresh code

The widget reference is available here.

[EDIT] You guys are the experts on using gtkdialog, but I'll give an example of what you can do with this Smile
Code:
#!/bin/sh

# NOTE: This example requires at least gtkdialog-0.7.21 (please visit
# http://code.google.com/p/gtkdialog/). Additionally if you are using
# Puppy Linux then you may find that an historical version of gtkdialog
# already exists in /usr/sbin, and if that is the case then you should
# modify the shell variable below to point to the new gtkdialog binary.

GTKDIALOG=gtkdialog

function funcImageToggle() {
   if [ $(< TOGGLE) = 1 ]; then
      ln -sf no.png toggle.png
      echo 0 > TOGGLE
   else
      ln -sf yes.png toggle.png
      echo 1 > TOGGLE
   fi
}
export -f funcImageToggle

if [ ! -f TOGGLE ]; then echo 0 > TOGGLE; funcImageToggle; fi

export MAIN_DIALOG='
<window title="btnImageToggle" resizable="false" width-request="300" height-request="100">
   <vbox homogeneous="true">
      <hbox homogeneous="true">
         <button>
            <variable>TOGGLEME</variable>
            <input file>toggle.png</input>
            <label>"Toggle Me!"</label>
            <action>funcImageToggle</action>
            <action type="refresh">TOGGLEME</action>
            <action type="refresh">TOGGLEMETOO</action>
         </button>
         <button tooltip-text="Toggle me too!">
            <variable>TOGGLEMETOO</variable>
            <input file>toggle.png</input>
            <action>funcImageToggle</action>
            <action type="refresh">TOGGLEMETOO</action>
            <action type="refresh">TOGGLEME</action>
         </button>
      </hbox>
   </vbox>
   <action signal="hide">exit:Exit</action>
</window>
'

$GTKDIALOG --center --program=MAIN_DIALOG

[EDIT] Added note about required version.
no.png
 Description   No image for script example (place into same folder as script)
 Filesize   720 Bytes
 Viewed   1053 Time(s)

no.png

yes.png
 Description   Yes image for script example (place into same folder as script)
 Filesize   663 Bytes
 Viewed   986 Time(s)

yes.png

btnImageToggle.gif
 Description   gtkdialog button image pixmap toggle flip-flop flipflop
 Filesize   13.68 KB
 Viewed   1093 Time(s)

btnImageToggle.gif


Edited_times_total
Back to top
View user's profile Send_private_message Visit_website 
zigbert


Joined: 29 Mar 2006
Posts: 5729
Location: Valåmoen, Norway

PostPosted: Thu 09 Jun 2011, 13:29    Post_subject:  

This will be very helpful


Sigmund

_________________
Stardust resources
Back to top
View user's profile Send_private_message Visit_website 
8-bit


Joined: 03 Apr 2007
Posts: 3368
Location: Oregon

PostPosted: Thu 09 Jun 2011, 14:33    Post_subject:  

Two things.
1st, has anyone compiled gtkdialog3 with the additions and is it available as a PET.

2nd, I noticed that in looking at the Puszcsa site that there is a member named "gray".
Any chance that he is the same "gray" that is shown as a member here?

I sent our gray an email and got an email stating it was undeliverable as the person did not exist.
Back to top
View user's profile Send_private_message 
Aitch


Joined: 04 Apr 2007
Posts: 6825
Location: Chatham, Kent, UK

PostPosted: Thu 09 Jun 2011, 16:20    Post_subject:  

8-bit

gray last posted on the forum on March 24th 2011, but I hadn't heard of him leaving....

PM link here

http://murga-linux.com/puppy/privmsg.php?mode=post&u=5585

he also has an interesting email address

Aitch Smile
Back to top
View user's profile Send_private_message 
8-bit


Joined: 03 Apr 2007
Posts: 3368
Location: Oregon

PostPosted: Thu 09 Jun 2011, 17:54    Post_subject:  

I do not know if I got it all included, but I am attaching a revised gtkdialog that I temporarily named "gtkdialog4"
It should have all the patches from Moose*, thunor, and patriot.

I could not get the checkmark png images for yes and no found and as a result, the one example does not work for me.

To try it with a script, just rename the call from gtkdialog to gtkdialog4.

And good luck!
gtkdialog4.tar.gz
Description  A good place to put this file for testing would be /root/my_applications/bin
It should contain all patches.
gz

 Download 
Filename  gtkdialog4.tar.gz 
Filesize  159.45 KB 
Downloaded  208 Time(s) 
Back to top
View user's profile Send_private_message 
Display_posts:   Sort by:   
Page 32 of 64 Posts_count   Goto page: Previous 1, 2, 3, ..., 30, 31, 32, 33, 34, ..., 62, 63, 64 Next
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » Off-Topic Area » Programming
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1115s ][ Queries: 13 (0.0160s) ][ GZIP on ]