antiright-devel
[Top][All Lists]
Advanced

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

[Antiright-devel] antiright gtkshell/Makefile gtkshell/gtkshell.h...


From: Jeffrey Bedard
Subject: [Antiright-devel] antiright gtkshell/Makefile gtkshell/gtkshell.h...
Date: Mon, 19 Mar 2007 09:33:07 +0000

CVSROOT:        /sources/antiright
Module name:    antiright
Changes by:     Jeffrey Bedard <jefbed> 07/03/19 09:33:07

Modified files:
        gtkshell       : Makefile gtkshell.h guidl.lex guidl.y 
                         image_button.c options.c terminal.c 
Added files:
        ACE-desktop/guidl: IDE.gdl 
        gtkshell       : guidl_util.c guidl_util.h 

Log message:
        Added a vte-based IDE.  Split out functionality from grammar.
        Reduced duplication.  Added tokens for terminal and window.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/antiright/ACE-desktop/guidl/IDE.gdl?cvsroot=antiright&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/Makefile?cvsroot=antiright&r1=1.15&r2=1.16
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/gtkshell.h?cvsroot=antiright&r1=1.26&r2=1.27
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/guidl.lex?cvsroot=antiright&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/guidl.y?cvsroot=antiright&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/image_button.c?cvsroot=antiright&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/options.c?cvsroot=antiright&r1=1.11&r2=1.12
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/terminal.c?cvsroot=antiright&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/guidl_util.c?cvsroot=antiright&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/antiright/gtkshell/guidl_util.h?cvsroot=antiright&rev=1.1

Patches:
Index: gtkshell/Makefile
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/Makefile,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- gtkshell/Makefile   19 Mar 2007 07:09:30 -0000      1.15
+++ gtkshell/Makefile   19 Mar 2007 09:33:07 -0000      1.16
@@ -36,7 +36,8 @@
        label.o button.o text.o updated_label.o updated_progress.o\
        updated_options.o add_options.o option_options.o dialog_options.o\
        file_dialog.o row.o containers.o geometry.o font.o dragdrop.o\
-       image_button.o y.tab.o lex.yy.o terminal.o terminal_options.o
+       image_button.o y.tab.o lex.yy.o terminal.o terminal_options.o\
+       guidl_util.o
 
 program=main.o 
 

Index: gtkshell/gtkshell.h
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/gtkshell.h,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -b -r1.26 -r1.27
--- gtkshell/gtkshell.h 19 Mar 2007 07:09:30 -0000      1.26
+++ gtkshell/gtkshell.h 19 Mar 2007 09:33:07 -0000      1.27
@@ -1,6 +1,6 @@
 /*
   AntiRight
-  (c) 2002-2006 Jeffrey Bedard
+  (c) 2002-2007 Jeffrey Bedard
   address@hidden
 
   This file is part of AntiRight.
@@ -38,15 +38,6 @@
 #include "y.tab.h"
 #endif /* !YYFILE */
 
-int
-yyparse();
-
-void
-gsh_free_parse_memory();
-
-void
-gsh_append_arg(char *);
-
 struct GSH_Rows
 {
        GtkWidget *h;
@@ -99,6 +90,7 @@
 #include "image_button.h"
 #include "terminal_options.h"
 #include "terminal.h"
+#include "guidl_util.h"
 
 void
 gsh_stack_init(struct GSH * gsh, int *argc, char ***argv);

Index: gtkshell/guidl.lex
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/guidl.lex,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- gtkshell/guidl.lex  16 Mar 2007 00:39:31 -0000      1.2
+++ gtkshell/guidl.lex  19 Mar 2007 09:33:07 -0000      1.3
@@ -4,10 +4,9 @@
 
 %}
 %%
-[A-Za-z] yylval.string=strdup(yytext); return CHAR;
 \"[^\"]*\"      {      
                        /* Remove quotes.  */ 
-                       yylval.string=strdup(yytext+1); 
+                       yylval.string=g_strdup(yytext+1); 
                        yylval.string[yyleng-2]='\0';
                        return STRING;
                }
@@ -24,6 +23,9 @@
 progress       return PROGRESS;
 updating       return UPDATING;
 buttons                return BUTTONS;
+terminal       return TERMINAL;
+window         return WINDOW;
+echo           return TOKEN_ECHO;
 
 [ \t\n]                /* ignore */;
 "//".*$                /* comment */;

Index: gtkshell/guidl.y
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/guidl.y,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- gtkshell/guidl.y    19 Mar 2007 07:09:30 -0000      1.3
+++ gtkshell/guidl.y    19 Mar 2007 09:33:07 -0000      1.4
@@ -1,4 +1,27 @@
 %{
+
+/*
+  AntiRight
+  (c) 2007 Jeffrey Bedard
+  address@hidden
+
+  This file is part of AntiRight.
+
+  AntiRight is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  AntiRight is distributed in the hope that it will be useful,
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  GNU General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with AntiRight; if not, write to the Free Software
+  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  
USA
+*/
+
 #include <stdio.h>
 #define YYFILE
 #include "gtkshell.h"
@@ -24,37 +47,20 @@
        return 1;
 }
 
-struct GSH * gsh_gsh;
-char **gsh_parsed_argv;
-int gsh_parsed_argc=0;
-
-void
-gsh_append_arg(char * arg)
-{
-       gsh_parsed_argc++;
-       gsh_parsed_argv=realloc(gsh_parsed_argv, sizeof(char*)*gsh_parsed_argc);
-       gsh_parsed_argv[gsh_parsed_argc-1]=strdup(arg);
-}
-
-void
-gsh_free_parse_memory()
-{
-       for(;gsh_parsed_argc>0; gsh_parsed_argc--)
-               free(gsh_parsed_argv[gsh_parsed_argc-1]);
-       free(gsh_parsed_argv);
-}
+extern char **gsh_parsed_argv;
+extern int gsh_parsed_argc;
 
 %}
 %union
 {
-       char * string;
-       int number;
+       gchar * string;
+       gint number;
 }
 %token IFS SC COMMA OPTION PROMPT VIEWER LABEL
 %token BUTTON END ADD UPDATING PROGRESS BUTTONS
+%token TERMINAL WINDOW TOKEN_ECHO
 %token <string> STRING
 %token <number> NUM
-%token <string> CHAR
 %%
 commands:
 /* empty */
@@ -66,139 +72,67 @@
 option
 |
 add
+|
+TOKEN_ECHO STRING
+{
+       puts($2);
+       g_free($2);
+}
 ;
 
 option:
-OPTION CHAR
-{
-       char * option_string;
-
-       asprintf(&option_string, "-o%s", $2);
-       gsh_append_arg(option_string);
-       free(option_string);
-}
-|
 OPTION STRING
 {
-       char option;
-
-       if(!strcmp($2, "undecorated"))
-               option='n';
-       else if(!strcmp($2, "frame_labels"))
-               option='f';
-       else if(!strcmp($2, "exit_on_activate"))
-               option='e';
-       else if(!strcmp($2, "horizontal_labels"))
-               option='h';
-       else if(!strcmp($2, "scrolled"))
-               option='s';
-       else
-               break;
-
-       {
-               char * option_string;
-
-               asprintf(&option_string, "-o%c", option);
-               gsh_append_arg(option_string);
-               free(option_string);
-       }
-}
-|
-OPTION CHAR NUM
-{
-       char * option_string;
-
-       asprintf(&option_string, "-o%s", $2);
-       gsh_append_arg(option_string);
-       free(option_string);
-       asprintf(&option_string, "%d", $3);
-       gsh_append_arg(option_string);
-       free(option_string);
+       gsh_guidl_string_option($2);    
 }
 |
 OPTION STRING STRING
 {
-       char option;
-
-       if(!strcmp($2, "geometry"))
-               option='g';
-       else
-       {
-               ARWARN("Invalid option.");
-               break;
-       }
-
-       {
-               char * option_string;
-
-               asprintf(&option_string, "-o%c", option);
-               gsh_append_arg(option_string);
-               free(option_string);
-               gsh_append_arg($3);
-       }
+       gsh_guidl_string_arg_option($2, $3);
 }
 |
 OPTION STRING NUM
 {
-       char option;
-
-       if(!strcmp($2, "update_frequency"))
-               option='u';
-       if(!strcmp($2, "rows"))
-               option = 'r';
-       else
-               break;
-
-       {
-               char * option_string;
-
-               asprintf(&option_string, "-o%c", option);
-               gsh_append_arg(option_string);
-               free(option_string);
-               asprintf(&option_string, "%d", $3);
-               gsh_append_arg(option_string);
-               free(option_string);
-       }
+       gsh_guidl_string_num_arg_option($2, $3);
 }
 ;
 
 add:
 ADD PROMPT STRING
 {
-       gsh_append_arg((char *)"-at");
-       gsh_append_arg($3);
+       gsh_guidl_add("-at", $3);
 }
 |
 ADD VIEWER STRING
 {
-       gsh_append_arg((char *)"-ae");
-       gsh_append_arg($3);
+       gsh_guidl_add("-ae", $3);
 }
 |
 ADD LABEL STRING
 {
-       gsh_append_arg((char *)"-al");
-       gsh_append_arg($3);
-       ARBUG($3);
+       gsh_guidl_add("-al", $3);
 }
 |
-ADD BUTTON STRING
-{
-       gsh_append_arg($3);
-       ARBUG($3);
-}
+ADD BUTTON button
 |
 ADD UPDATING PROGRESS STRING
 {
-       gsh_append_arg((char*)"-aup");
-       gsh_append_arg($4);
-
+       gsh_guidl_add("-aup", $4);
 }
 |
 ADD UPDATING LABEL STRING
 {
-       gsh_append_arg((char*)"-aul");
-       gsh_append_arg($4);
+       gsh_guidl_add("-aul", $4);
+}
+|
+ADD TERMINAL STRING
+{
+       gsh_guidl_add("-as", $3);
+}
+|
+ADD WINDOW
+{
+       gsh_append_arg((gchar *)"-aw");
 }
 |
 ADD BUTTONS buttons
@@ -216,6 +150,7 @@
 STRING
 {
        gsh_append_arg($1);
+       g_free($1);
 }
 ;
 

Index: gtkshell/image_button.c
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/image_button.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- gtkshell/image_button.c     19 Mar 2007 07:09:30 -0000      1.7
+++ gtkshell/image_button.c     19 Mar 2007 09:33:07 -0000      1.8
@@ -36,6 +36,7 @@
        {
                GtkWidget * label;
                GtkWidget * hrow;
+
                label=gtk_bin_get_child(GTK_BIN(gsh->button));
                gtk_widget_ref(label);
                gtk_container_remove(GTK_CONTAINER(gsh->button), label);
@@ -67,14 +68,14 @@
                ARIFB(g_file_test(prefixed_name, G_FILE_TEST_EXISTS))
                {
 #ifdef DEBUG
-                       puts("using prefixed image");
+                       ARBUG("using prefixed image");
 #endif /* DEBUG */
                        image = gtk_image_new_from_file(prefixed_name);
                }
                else
                {
 #ifdef DEBUG
-                       puts("trying stock image");
+                       ARBUG("trying stock image");
 #endif /* DEBUG */
                        image = gtk_image_new_from_stock(
                                (const gchar *)name,

Index: gtkshell/options.c
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/options.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- gtkshell/options.c  16 Mar 2007 00:39:31 -0000      1.11
+++ gtkshell/options.c  19 Mar 2007 09:33:07 -0000      1.12
@@ -55,7 +55,7 @@
                gsh_append_arg((char*)"guidl");
                yyparse();
                gsh_parse_arguments(gsh, gsh_parsed_argc, gsh_parsed_argv);
-               //gsh_free_parse_memory();
+               /* Free parse memory in main.  */
                break;
        case 'o':
                gsh_handle_option_arguments(gsh, argc, argv, counter);
@@ -64,7 +64,7 @@
                gsh_append_arg((char*)"guidl");
                yyparse();
                gsh_parse_arguments(gsh, gsh_parsed_argc, gsh_parsed_argv);
-               //gsh_free_parse_memory();
+               /* Free parse memory in main.  */
                break;
        default:
                g_warning("%s:  %s undefined\n", argv[0], argv[(*counter)]);

Index: gtkshell/terminal.c
===================================================================
RCS file: /sources/antiright/antiright/gtkshell/terminal.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- gtkshell/terminal.c 19 Mar 2007 07:09:30 -0000      1.2
+++ gtkshell/terminal.c 19 Mar 2007 09:33:07 -0000      1.3
@@ -51,16 +51,41 @@
 {
        GtkWidget * term;
 
+       /* Assign a shortcut reference.  */
        term=gsh->terminal.widget;
 
        set_size(gsh);
-       vte_terminal_set_allow_bold(VTE_TERMINAL(term), TRUE);
+       /*vte_terminal_set_allow_bold(VTE_TERMINAL(term), TRUE);*/
        vte_terminal_set_backspace_binding(VTE_TERMINAL(term),
                                           VTE_ERASE_ASCII_BACKSPACE);
        set_font(gsh);
        vte_terminal_set_background_transparent(VTE_TERMINAL(term), TRUE);
 }
 
+static void
+set_script_permissions(gint fd)
+{
+       /* Set the script file permissions such that only the user has read,
+        * write and execute privileges.  Check for success.  */
+       if (fchmod(fd, S_IXUSR | S_IRUSR | S_IWUSR) != 0)
+               ARERR("script file does not exist");
+}
+
+static gint
+setup_script_file(gchar **name)
+{
+       gint fd;
+
+       /* Open temporary file, store file descriptor in FD and file name in
+        * NAME.  NAME is modified in calling function.  */
+       fd = g_file_open_tmp("gshterm.XXXXXX", name, NULL);
+       /* Check for success.  */
+       ARASSERT(fd != -1);
+
+       return fd;
+}
+
+/* This is a workaround for vte's fscking up of option arrays.  */
 /* Returned value must be freed.  */
 static gchar *
 gsh_terminal_command_script(const gchar *command)
@@ -73,41 +98,44 @@
        ARBUG("gshterm_command_script()");
 #endif                         /* DEBUG */
 
+       /* No need to continue of no command has been specified.  */
        ARPASSERT(command);
 
-       /* This is a workaround for vte's fscking up of option arrays.  */
-
-       fd = g_file_open_tmp("gshterm.XXXXXX", &script_name, NULL);
-       ARASSERT(fd != -1);
+       /* Create script temporary file.  */
+       fd=setup_script_file(&script_name);
 
        /*
         * Do this immediately after opening in order to reduce the
         * possiblity of script modification exploit.
         */
-       if (fchmod(fd, S_IXUSR | S_IRUSR | S_IWUSR) != 0)
-               ARERR("script file does not exist");
+       set_script_permissions(fd);
        
+       /* Get a file pointer associated with the file descriptor.  Check for
+        * success.  */
        ARIFNP((script=fdopen(fd, "w")))
                ARERR("script file could not be opened");
 
-       //fflush(script);
-       if(fsync(fd) == EOF)
+       /* Write file to disk.  Check for success.  */
+       if(fsync(fd) == -1)
                ARERR("cannot write script file");
        
        ARASSERT(fprintf(script, "#!/bin/sh\n%s\n", command) != -1);
        fclose(script); /* Close and flush buffers.  */
 
 #ifdef DEBUG
+       /* Display script contents.  */
        sysprintf("cat %s", script_name);
        ARBUG("end gshterm_command_script()");
 #endif                         /* DEBUG */
 
+       /* Calling function should free SCRIPT_NAME.  */
        return (script_name);
 }
 
 static void
 gsh_terminal_run(struct GSH * gsh, const gchar * command)
 {
+       /* Get command to run.  */
        gsh->terminal.script=gsh_terminal_command_script(command);
 
        /* Run the script in the terminal widget.  */
@@ -121,15 +149,19 @@
 void
 gsh_setup_terminal(struct GSH * gsh, const gchar * command)
 {
+       /* VTE-based terminal.  */
        gsh->terminal.widget=vte_terminal_new();
 
+       /* Set properties.  */
        gsh_set_terminal_options(gsh);
+       /* Display widget.  */
        gtk_widget_show(gsh->terminal.widget);
 
+       /* Exit from the application if the terminal process dies.  */
        g_signal_connect(G_OBJECT(gsh->terminal.widget), "child-exited",
                         G_CALLBACK(gtk_main_quit), NULL);
 
-
+       /* Add to the gtkshell row/column grid.  */
        gsh_manage(gsh, gsh->terminal.widget);
 
        gsh_terminal_run(gsh, command);

Index: ACE-desktop/guidl/IDE.gdl
===================================================================
RCS file: ACE-desktop/guidl/IDE.gdl
diff -N ACE-desktop/guidl/IDE.gdl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ ACE-desktop/guidl/IDE.gdl   19 Mar 2007 09:33:07 -0000      1.1
@@ -0,0 +1,21 @@
+option "rows" 2;
+
+
+option "terminal font" "Mono 12";
+option "terminal width" 80;
+option "terminal height" 32;
+add terminal "vi";
+
+option "terminal font" "Mono 10";
+option "terminal height" 8;
+add terminal "$SHELL";
+
+option "rows" 16;
+
+add buttons 
+       "make", 
+       "make clean", 
+       "make install", 
+       "make run",
+       "make test";
+

Index: gtkshell/guidl_util.c
===================================================================
RCS file: gtkshell/guidl_util.c
diff -N gtkshell/guidl_util.c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ gtkshell/guidl_util.c       19 Mar 2007 09:33:07 -0000      1.1
@@ -0,0 +1,143 @@
+/*
+  AntiRight
+  (c) 2007 Jeffrey Bedard
+  address@hidden
+
+  This file is part of AntiRight.
+
+  AntiRight is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  AntiRight is distributed in the hope that it will be useful,
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  GNU General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with AntiRight; if not, write to the Free Software
+  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  
USA
+*/
+
+#include "gtkshell.h"
+
+char **gsh_parsed_argv;
+int gsh_parsed_argc=0;
+
+void
+gsh_append_arg(gchar * arg)
+{
+       gsh_parsed_argc++;
+       gsh_parsed_argv=realloc(gsh_parsed_argv, sizeof(char*)*gsh_parsed_argc);
+       gsh_parsed_argv[gsh_parsed_argc-1]=strdup(arg);
+}
+
+void
+gsh_free_parse_memory()
+{
+       for(;gsh_parsed_argc>0; gsh_parsed_argc--)
+               free(gsh_parsed_argv[gsh_parsed_argc-1]);
+       free(gsh_parsed_argv);
+}
+
+void
+gsh_guidl_string_option(gchar * string)
+{
+       gchar option;
+
+       if(!strcmp(string, "undecorated"))
+               option='n';
+       else if(!strcmp(string, "frame_labels"))
+               option='f';
+       else if(!strcmp(string, "exit_on_activate"))
+               option='e';
+       else if(!strcmp(string, "horizontal_labels"))
+               option='h';
+       else if(!strcmp(string, "scrolled"))
+               option='s';
+       else
+       {
+               ARWARN("invalid option");
+               return;
+       }
+
+       {
+               char * option_string;
+
+               ar_asprintf(&option_string, "-o%c", option);
+               gsh_append_arg(option_string);
+               g_free(option_string);
+       }
+
+       g_free(string);
+}
+
+void
+gsh_guidl_string_arg_option(gchar * option, gchar * arg)
+{
+       gchar * option_switch;
+       gchar * option_string;
+
+       option_switch=NULL;
+
+       if(!strcmp(option, "geometry"))
+               option_switch=g_strdup("g");
+       else if(!strcmp(option, "terminal font"))
+               option_switch=g_strdup("tf");
+       else
+       {
+               ARWARN("Invalid option.");
+               return;
+       }
+
+
+       ar_asprintf(&option_string, "-o%s", option_switch);
+       g_free(option_switch);
+       gsh_guidl_add(option_string, arg);
+       free(option_string);
+
+       g_free(option);
+}
+
+void
+gsh_guidl_string_num_arg_option(gchar * option, gint num)
+{
+       gchar * option_switch;
+       gchar * option_string;
+
+       option_switch=NULL;
+
+       if(!strcmp(option, "update_frequency"))
+               option_switch = g_strdup("u");
+       else if(!strcmp(option, "rows"))
+               option_switch = g_strdup("r");
+       else if(!strcmp(option, "terminal height"))
+               option_switch = g_strdup("th");
+       else if(!strcmp(option, "terminal width"))
+               option_switch = g_strdup("tw");
+       else
+       {
+               ARWARN("invalid option");
+               return;
+       }
+
+       ar_asprintf(&option_string, "-o%s", option_switch);
+       g_free(option_switch);
+       gsh_append_arg(option_string);
+       free(option_string);
+       asprintf(&option_string, "%d", num);
+       gsh_append_arg(option_string);
+       free(option_string);
+
+       g_free(option);
+}
+
+void
+gsh_guidl_add(const char * switches, gchar * argument)
+{
+       gsh_append_arg((gchar *)switches);
+       gsh_append_arg(argument);
+       g_free(argument);
+}
+

Index: gtkshell/guidl_util.h
===================================================================
RCS file: gtkshell/guidl_util.h
diff -N gtkshell/guidl_util.h
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ gtkshell/guidl_util.h       19 Mar 2007 09:33:07 -0000      1.1
@@ -0,0 +1,51 @@
+/*
+  AntiRight
+  (c) 2007 Jeffrey Bedard
+  address@hidden
+
+  This file is part of AntiRight.
+
+  AntiRight is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  AntiRight is distributed in the hope that it will be useful,
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  GNU General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with AntiRight; if not, write to the Free Software
+  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  
USA
+*/
+
+#ifndef GSH_GUIDL_UTIL_H
+#define GSH_GUIDL_UTIL_H
+
+int
+yylex();
+
+int
+yyparse();
+
+void
+gsh_append_arg(gchar * arg);
+
+void
+gsh_free_parse_memory();
+
+void
+gsh_guidl_string_option(gchar * string_option);
+
+void
+gsh_guidl_string_arg_option(gchar * option, gchar * arg);
+
+void
+gsh_guidl_string_num_arg_option(gchar * option, gint num);
+
+/* SWITCHES is not freed.  If dynamically allocated, you must free.  */
+void
+gsh_guidl_add(const char * switches, gchar * argument);
+
+#endif /* not GSH_GUIDL_UTIL_H */




reply via email to

[Prev in Thread] Current Thread [Next in Thread]