Introduction and question



************************************************************************
*       Do not Cc: me, because I READ THIS LIST, if I write here       *
*    Keine Cc: am mich, ich LESE DIESE LISTE wenn ich hier schreibe    *
************************************************************************

Hello *,

My name is Michelle, live in Strasbourg, being Debian GNU/Linux  Consul-
tant and since August 2007 I have my Doctor in  Informatic.  Since  some
weeks now I am learning perl and it is great programming language  which
I unfortunately learn at least 15 years to late...  :-/

Now I have begun, to port some older "Programs" coded in  BaSH  to  Perl
and I want to change the Xdialog stuff to a real GTK-Dialog.

Since Xdialog can only show one thing at once, I have the singel options
in a "treeview", but now I want to use "notepad" with this nice tabs.

OK, my programs write the optins to singel files (one  file  per  Option
like "courier-imap") and I use "cat" to read its value.  I do  not  want
to change this...

In BaSH I used:

----[ STDIN ]-----------------------------------------------------------
  for NAME1 in $(find ${CFGDIR} -type f -maxdepth 1) ; do
    VAL=$(cat ${NAME1})
    NAME=$(basename ${NAME1})
    eval "export ${VARPREFIX}${NAME}=\${VAL}"
  done
------------------------------------------------------------------------

Note:  ${VARPREFIX} is:  VARPREFIX=$(basename $0)_

1st question:  How do I do this in Perl?

Then, the "notepad" dialog...
I want to have a button "Apply"  which  write  the  new  entered  values
to the config dir whithout closing the dialog where under BaSH I used:

----[ STDIN ]-----------------------------------------------------------
  (env |grep "^${VARPREFIX}" |sed "s|^${VARPREFIX}||g") |
  while read FULL
  do
    NAME=$(echo "${FULL}" |cut -d '=' -f1)
    VAL=$(echo  "${FULL}" |cut -d '=' -f2-)
    echo "${VAL}" >${CFGDIR}/${NAME}
  done
------------------------------------------------------------------------

2nd question:  How do I do this in Perl?

3th question:  HOW do I make a "notepad" dialog in "perl-gtk"?
               The first TAB should have the MAIN user interface and
               then the following TABs config stuff and such...

Thanks, Greetings and nice Day/Evening
    Michelle Konzack
    Systemadministrator
    24V Electronic Engineer
    Tamay Dogan Network
    Debian GNU/Linux Consultant


-- 
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack   Apt. 917                  ICQ #328449886
+49/177/9351947    50, rue de Soultz         MSN LinuxMichi
+33/6/61925193     67100 Strasbourg/France   IRC #Debian (irc.icq.com)

Attachment: signature.pgp
Description: Digital signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]