GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Sun Nov 23, 2014 2:39 pm

All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: [question] gtkdialog
PostPosted: Fri Aug 09, 2013 1:31 pm 
Offline

Joined: Tue Aug 06, 2013 5:42 pm
Posts: 3
Hi!
I found this on the forum

Code:
#! /bin/bash

##########################################################################
##########################################################################
##########################################################################
function mk_yesno(){
#USAGE: mk_yesno $"Question text?" "yes-button-icon" "yes-button-function" "no-button-icon" "no-button-function"
   export MAIN_DIALOG='
   <window title=" - Update-Notifier - " resizable="false" icon-name="computer">
   <vbox>
   <text use-markup="true" width-chars="40">
      <label>"'`echo $1`'"</label>
   </text>
   <hbox>
      <button>
         <label>"'`gettext " No "`'"</label>
         <input file icon="'`echo $4`'"></input>
         <action>'`echo $5`'</action>
         <action type="exit">no button clicked</action>
      </button>
      <button>
         <label>"'`gettext " Yes "`'"</label>
         <input file icon="'`echo $2`'"></input>
         <action>'`echo $3`'</action>
         <action type="exit">yes button clicked</action>
      </button>
   </hbox>
   </vbox>
   </window>
   '
}
mk_yesno $"Would you like update-notifier to give pop-up status notifications?" "help-faq" 'print_this "yes button clicked"' "stop" 'print_this "no button clicked"'
gtkdialog --center --include=test.functions --program=MAIN_DIALOG

mk_yesno $"Would you like to talk about linux?" "irc_section" 'print_this "yes button clicked"' "gtk-quit" 'print_this "no button clicked"'
gtkdialog --center --include=test.functions --program=MAIN_DIALOG


##########################################################################
##########################################################################
##########################################################################

sleep 2
exit


1. This is bash with ... ?
I don't know what it is? , Why have parse html </ >
Quote:
<button>
<label>"'`gettext " Yes "`'"</label>

2. Did someone can answer Where can I find more information about this ?

3. Can I create any GUI with this? OR only like Gzenity yad (messages)
4. I know what it is zenity and yad but this only creates messages.
Gdialog and Qdialog is like zenity and yad ?
5. What is the best to create beautifull GUI for applications - bash scripts ?


Last edited by tele on Sat Oct 12, 2013 4:37 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: [Solved] gtk question
PostPosted: Sat Oct 12, 2013 4:37 pm 
Offline

Joined: Tue Aug 06, 2013 5:42 pm
Posts: 3
Refresh, I found tutorial
http://xpt.sourceforge.net/techdocs/lan ... es/single/

This is gtkdialog

This is good because working like bash script,
but I looking IDE for gtkdialog,

I can find , I' trying use glade like this:

Code:
#! /bin/bash
gtkdialog --glade-xml=gladeZw.glade /
--program=window1


but not working :-(

Quote:
$ ./cos.sh

(gtkdialog:31212): libglade-WARNING **: Expected <glade-interface>. Got <interface>.

(gtkdialog:31212): libglade-WARNING **: did not finish in PARSER_FINISH state

(gtkdialog:31212): libglade-CRITICAL **: glade_xml_get_widget: assertion `self != NULL' failed

** (gtkdialog:31212): ERROR **: Can not load '(null)' from file 'gladeZw.glade'
./cos.sh: line 2: 31212 PuƂapka debuggera/breakpoint gtkdialog --glade-xml=gladeZw.glade /
./cos.sh: line 3: --program=window1: command not found


Edit:
ok i guess, glade use gtk, gtkdialog is only part gtk so not will work,
but I saw a video on youtube and on debian can run from the console glade project,
how above, not important, does not work it does not work.
Topic to close.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: Google [Bot], Google Adsense [Bot], Yahoo [Bot] and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group