From e9ae80694875f869892f13f4fcaf1170a00dea41 Mon Sep 17 00:00:00 2001 From: toma Date: Wed, 25 Nov 2009 17:56:58 +0000 Subject: Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kommander/examples/tutorial/cmdline.kmdr | 108 +++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 kommander/examples/tutorial/cmdline.kmdr (limited to 'kommander/examples/tutorial/cmdline.kmdr') diff --git a/kommander/examples/tutorial/cmdline.kmdr b/kommander/examples/tutorial/cmdline.kmdr new file mode 100644 index 00000000..0db801d2 --- /dev/null +++ b/kommander/examples/tutorial/cmdline.kmdr @@ -0,0 +1,108 @@ + +Form1 + + + Form1 + + + + 0 + 0 + 462 + 340 + + + + Form1 + + + + + + + + + unnamed + + + 11 + + + 6 + + + + + Usage: kmdr-executor cmdline.kmdr [BUTTON='title'] arg1 ... + + + + ListBox1 + + + + + Spacer1 + + + Horizontal + + + Expanding + + + + 149 + 0 + + + + + + ExecButton1 + + + Read command line + + + + # Put command-line arguments into list +dcop @dcopid KommanderIf clearList ListBox1 +VALUE=`dcop @dcopid KommanderIf global ARGS` +for i in $VALUE; do + dcop @dcopid KommanderIf addListItem ListBox1 "$i" 999 +done + +ARGS=`dcop @dcopid KommanderIf global ARGCOUNT` +dcop @dcopid KommanderIf addListItem ListBox1 "Arguments count: $ARGS" 999 + + +# Read button text +BUTTONTEXT=`dcop @dcopid KommanderIf global BUTTON` +if [ "$BUTTONTEXT" ]; then + dcop @dcopid KommanderIf changeWidgetText ExecButton1 "$BUTTONTEXT" +fi + + + + + + Spacer3 + + + Horizontal + + + Expanding + + + + 148 + 0 + + + + + + + -- cgit v1.2.3