Gtkdialog Tutorial Manual

New features which should be implemented in Porteus; suggestions are welcome. All questions or problems with testing releases (alpha, beta, or rc) should go in their relevant thread here, rather than the Bug Reports section.
don570
Contributor
Contributor
Posts: 99
Joined: 01 Jun 2012, 00:37
Location: Ontario

Gtkdialog Tutorial Manual

Post#1 by don570 » 16 Oct 2013, 22:36

I wrote a manual to introduce Bash programmers to the power
of Gtkdialog GUI scripting. It's available for download.
(untick the box to avoid installing the downloader)

http://www.datafilehost.com/d/6c860d52

EDIT: new version 2.4
___________________________________________________

For examples of apps that can be developed using Gtkdialog
http://www.murga-linux.com/puppy/viewtopic.php?t=69282

Example: pburn by Zigbert has been converted to Porteus
Last edited by don570 on 03 Dec 2013, 21:18, edited 4 times in total.

User avatar
mocabilly
White ninja
White ninja
Posts: 21
Joined: 12 Jan 2011, 17:53
Distribution: Mint-Porteus
Location: Belgium

Re: Gtkdialog Tutorial Manual

Post#2 by mocabilly » 18 Oct 2013, 22:06

Hi don570,

Thnx for the great tutorial.

Kind regards,

Mocabilly
There are only 10 kind of people in this world, those who can read binary and those who can't.

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: Gtkdialog Tutorial Manual

Post#3 by brokenman » 19 Oct 2013, 00:13

Great work. This is a great asset to gtkdialog. I hope people start writing stuff and unleashing the full power of gtkdialog.
How do i become super user?
Wear your underpants on the outside and put on a cape.

don570
Contributor
Contributor
Posts: 99
Joined: 01 Jun 2012, 00:37
Location: Ontario

Re: Gtkdialog Tutorial Manual

Post#4 by don570 » 19 Oct 2013, 20:38

Improved and updated to version 2.0

don570
Contributor
Contributor
Posts: 99
Joined: 01 Jun 2012, 00:37
Location: Ontario

Re: Gtkdialog Tutorial Manual

Post#5 by don570 » 31 Oct 2013, 23:17

New version 2.1 available in first post.

don570
Contributor
Contributor
Posts: 99
Joined: 01 Jun 2012, 00:37
Location: Ontario

Re: Gtkdialog Tutorial Manual

Post#6 by don570 » 09 Nov 2013, 20:52

new version 2.2 available in first post

don570
Contributor
Contributor
Posts: 99
Joined: 01 Jun 2012, 00:37
Location: Ontario

Re: Gtkdialog Tutorial Manual

Post#7 by don570 » 03 Dec 2013, 21:16

I've now reached version 2.4 of the manual.
See first post.

User avatar
francois
Contributor
Contributor
Posts: 6434
Joined: 28 Dec 2010, 14:25
Distribution: xfce plank porteus nemesis
Location: Le printemps, le printemps, le printemps... ... l'hiver s'essoufle.

Re: Gtkdialog Tutorial Manual

Post#8 by francois » 09 Dec 2016, 01:41

gtkdialog:
http://www.tecmint.com/gtkdialog-create ... log-boxes/

Gtkdialog (or gtkdialog) is an open source nifty utility for creating and building GTK+ Interfaces and Dialog Boxes with the help of Linux shell scripts and using GTK library, as well as using an xml-like syntax, which makes easy to create interfaces using gtkdialog. It is much similar to most famous tool called Zenity, but it comes with some useful customizable features that enables you to easily create many widgets like vbox, hbox, button, frame, text, menu, and a lot more. ... and more.

Thanks Don. :)
Prendre son temps, profiter de celui qui passe.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Gtkdialog Tutorial Manual

Post#9 by Bogomips » 09 Dec 2016, 12:46

francois wrote:Thanks Don. :)
A bit belated :twisted: (beat you to it Ed 8) )
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
francois
Contributor
Contributor
Posts: 6434
Joined: 28 Dec 2010, 14:25
Distribution: xfce plank porteus nemesis
Location: Le printemps, le printemps, le printemps... ... l'hiver s'essoufle.

Re: Gtkdialog Tutorial Manual

Post#10 by francois » 09 Dec 2016, 22:19

Don't laugh about old men. :(
Prendre son temps, profiter de celui qui passe.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: Gtkdialog Tutorial Manual

Post#11 by Ed_P » 10 Dec 2016, 21:02

Yeah.

Kids today. :(
Ed

User avatar
Blaze
DEV Team
DEV Team
Posts: 3869
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Gtkdialog Tutorial Manual

Post#12 by Blaze » 13 Dec 2016, 19:01

Hello, everybody!

I Am trying to writing on gtkdialog simple application for automatically authorization on the government site.
This program after clicking on the user button is automatically opening web site http://government-site.org via Mozilla Firefox browser and automatically inserts login and password of chosen user.

I have the same application by me on AutoIt for Window$
AutoIt v3 is a freeware BASIC-like scripting language designed for automating the Windows GUI and general scripting.
But I don't have idea how to add two actions (for four buttons):

1) for automatic insertion of user (visible_user_field) and password (visible_password_field) to the two fields of this html page

Code: Select all

<input id="visible_user_field" style="width: 100%" name="userName" tabindex="1" autocomplete="off" type="text">
<input id="visible_password_field" style="width: 100%" name="password" tabindex="2" autocomplete="off" type="password"> 
2) plus automatic pressing 'Enter' button of keyboard after 1st action or automatic pressing the button "Вход в систему"[/color]

Code: Select all

<input name="loginButton" id="loginButton" value="Вход в систему" onclick="OnClick()" type="button"> 
Вход в систему it's Sign in
Пользователь it's User
Пароль it's Password
source of gtkdialog (example)

Code: Select all

#!/bin/bash 
GTKDIALOG=gtkdialog 
export MAIN_DIALOG=' 
<window title="Title of app" icon-name="gtk-about" resizable="true" width-request="350" height-request="170"> 

<vbox> 

<button>
<label>User 1</label>
<action>exec firefox http://government-site.org</action>
</button>

<button>
<label>User 2</label>
<action>exec firefox http://government-site.org</action>
</button>

<button>
<label>User 3</label>
<action>exec firefox http://government-site.org</action>
</button>

<button>
<label>User 4</label>
<action>exec firefox http://government-site.org</action>
</button>

<button>
<label>Exit</label>
<action type="exit">Cancel</action>
</button>

</vbox>

</window>
'
case $1 in
-d | --dump) echo "$MAIN_DIALOG" ;;
*) $GTKDIALOG --program=MAIN_DIALOG --center ;;
esac
source of html - download

Code: Select all

                    <tr>
                        <td class="bold">
                            <label for="visible_user_field">
                                Пользователь:
                            </label>
                        </td>
                        <td style="text-align: right;">
                            <input id="visible_user_field" style="width: 100%" name="userName" tabindex="1" autocomplete="off" type="text">
                        </td>
                    </tr>
                    <tr>
                        <td class="bold">
                            <label for="visible_password_field">
                                Пароль:
                            </label>
                        </td>
                        <td style="text-align: right;">
                            <input id="visible_password_field" style="width: 100%" name="password" tabindex="2" autocomplete="off" type="password">
                        </td>
                    </tr> 
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

User avatar
Blaze
DEV Team
DEV Team
Posts: 3869
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Gtkdialog Tutorial Manual

Post#13 by Blaze » 25 Mar 2017, 19:22

Any suggestions are welcome.
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

Post Reply