]> git.lyx.org Git - lyx.git/commitdiff
Small fixes notified by Angus and patch from Kayan!
authorJürgen Vigna <jug@sad.it>
Wed, 12 Jul 2000 13:24:24 +0000 (13:24 +0000)
committerJürgen Vigna <jug@sad.it>
Wed, 12 Jul 2000 13:24:24 +0000 (13:24 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@878 a592a061-630c-0410-9148-cb99ea01b6c8

13 files changed:
ChangeLog
lib/Makefile.am
lib/build-listerrors [new file with mode: 0755]
lib/examples/Literate.lyx
src/BufferView2.C
src/Literate.C
src/Literate.h
src/frontends/xforms/FormTabular.C
src/frontends/xforms/FormTabular.h
src/frontends/xforms/form_tabular.C
src/frontends/xforms/form_tabular.h
src/frontends/xforms/forms/form_tabular.fd
src/insets/insettabular.C

index a363c47bd40bc6dc04d8a2212ee83f08eebbe4cb..c402ed9426ac22236fe9bfb09848136e1c07cbaa 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
        * src/lyx_main.C (commandLineHelp): remove -display from command
        line help.
 
+2000-07-09  Kayvan A. Sylvan  <kayvan@sylvan.com>
+
+       * lib/Makefile.am: added lib/build-listerrors to DIST tarfile.
+       Also put in Makefile rules for building the ``listerrors''
+       program for parsing errors from literate programs written in LyX.
+
+       * lib/build-listerrors: Added small shell script as part of compile
+       process. This builds a working ``listerrors'' binary if noweb is
+       installed and either 1) the VNC X server is installed on the machine,
+       or 2) the user is compiling from within a GUI. The existence of a GUI
+       is necessary to use the ``lyx --export'' feature for now. This
+       hack can be removed once ``lyx --export'' no longer requires a GUI to
+       function.
+
+2000-07-09  Bernard Michael Hurley <bernardh@westherts.ac.uk>
+
+       * lib/examples/Literate.lyx, src/Literate.[Ch]: Error messages are
+       now passed back correctly from gcc and placed "under" error
+       buttons in a Literate LyX source.
+
 2000-07-08  Dekel Tsur  <dekel@math.tau.ac.il>
 
        * src/text.C (GetColumnNearX): Better behavior when a RTL
index cc794cccb062aee17605ee0facb6d7541f0ee6bb..4f3dcb820bb646209e5228fd5ae91ac13f790a59 100644 (file)
@@ -4,6 +4,7 @@ DISTCLEANFILES = *.orig *.rej *~ *.bak core textclass.lst packages.lst \
 pkgdata_SCRIPTS = configure configure.cmd
 MAINTAINERCLEANFILES = $(srcdir)/Makefile.in
 SUBDIRS    = reLyX
+bin_SCRIPTS = listerrors
 
 BIND = bind/*.bind
 CLIPART = clipart/*.eps
@@ -29,7 +30,7 @@ pkgdata_DATA = lyxrc.example CREDITS chkconfig.ltx lyxrc.defaults \
 LYXLIBDIRS = bind clipart doc examples images kbd layouts scripts templates tex
 
 EXTRA_DIST = CREDITS chkconfig.ltx configure.cmd lyxrc.example \
-       external_templates $(LYXLIBDIRS)
+       external_templates $(LYXLIBDIRS) build-listerrors
 
 libinstalldirs:
        for dir in $(LYXLIBDIRS) ; do \
@@ -55,3 +56,5 @@ dist-hook:
        { cvs -Q export -r HEAD -d doc lyxdoc || \
          echo "WARNING: Unable to get LyX Documentation from CVS!" ; true ; }
 
+listerrors: examples/Literate.lyx
+       ./build-listerrors
diff --git a/lib/build-listerrors b/lib/build-listerrors
new file mode 100755 (executable)
index 0000000..629d031
--- /dev/null
@@ -0,0 +1,83 @@
+#!/bin/sh
+#
+# Attempt to build listerrors (see examples/Literate.lyx) at build-time
+#
+# Author: Kayvan Sylvan <kayvan@sylvan.com>
+
+fakeprogram()
+{
+    L=listerrors
+    echo "#!/bin/sh" > $L
+    echo 'echo "This is NOT the listerrors program."' >> $L
+    echo 'echo ""' >> $L
+    echo 'echo "Here was the problem when we tried to build listerrors:"' >> $L
+    echo echo "$1" >> $L
+    chmod +x $L
+    exit 0
+}
+
+mywhich()
+{
+    arg=$1
+    for i in `echo $PATH | sed 's/:/ /g'`
+    do
+        if [ -x $i/$arg ]
+        then
+            echo $i/$arg
+        fi
+    done
+}
+
+if [ -r ../src/lyx ]
+then
+    lyx=../src/lyx
+else
+    lyx=`mywhich lyx`
+fi
+
+if [ -z "$lyx" ]
+then
+    echo "You must build lyx first to build listerrors."
+    exit 1
+fi
+
+notangle=`mywhich notangle`
+
+if [ -z "$notangle" ]
+then
+    fakeprogram "The NOWEB notangle was not found."
+fi
+
+vncserver=`mywhich vncserver`
+if [ -z "$vncserver" ]
+then
+    # See if DISPLAY is set
+    #
+    if [ -z "$DISPLAY" ]
+    then
+        fakeprogram "Could not export Literate.nw. Export needs GUI, fix lyx!"
+    else
+        $lyx --export tex examples/Literate.lyx
+    fi
+else
+    # Use the vncserver to make a silent export
+    if [ -r $HOME/.vnc/passwd ]
+    then
+        had_vnc_passwd=1
+    else
+       mkdir $HOME/.vnc > /dev/null 2>&1
+        had_vnc_passwd=0
+        touch $HOME/.vnc/passwd; chmod 700 $HOME/.vnc/passwd
+    fi
+    $vncserver :10 -depth 16
+    DISPLAY=:10
+    export DISPLAY
+    $lyx --export tex examples/Literate.lyx
+    $vncserver -kill :10
+    if [ $had_vnc_passwd -eq 0 ]
+    then
+        rm $HOME/.vnc/passwd
+    fi
+fi
+mv examples/Literate.tex Literate.nw
+$notangle -Rbuild-script Literate.nw | sh
index 47db33766a1c829d19bdb7035ceb1ed603bfc7da..647af802ed108357b969a1c10c185de726ff2066 100644 (file)
@@ -1,6 +1,5 @@
-#This file was created by <wiensk> Tue Feb 23 22:25:52 1999
-#LyX 1.0 (C) 1995-1999 Matthias Ettrich and the LyX Team
-\lyxformat 2.15
+#LyX 1.1 created this file. For more info see http://www.lyx.org/
+\lyxformat 2.16
 \textclass literate-article
 \language default
 \inputencoding default
@@ -33,6 +32,12 @@ An example program
 Edmar Wienskoski Jr.
 \newline 
 edmar-w-jr@technologist.com
+\begin_float footnote 
+\layout Standard
+
+Modified by Bernard Michael Hurley bernardh@westherts.ac.uk ---- Don't blame
+ Edmar for any errors that have crept in!
+\end_float 
 \layout Date
 
 
@@ -43,7 +48,7 @@ today
 \layout Standard
 
 
-\begin_inset LatexCommand \tableofcontents
+\begin_inset LatexCommand \tableofcontents{}
 
 \end_inset 
 
@@ -70,12 +75,12 @@ In this document we present a filter that recognizes compilation error messages
 
 The filter is required to read from standard input, parse for error messages
  and copy the error messages to the standard output.
- During the output process, the filter must present the error messages in a
- format that LyX can interpret, currently, the LaTeX error message format.
- Of course, nothing will prevent future LyX releases from being able to read
- other formats as well (like gcc error messages for example).
- This mechanism is necessary to fully explore the literate programming
tool's capabilities.
+ During the output process, the filter must present the error messages in
format that LyX can interpret, currently, the LaTeX error message format.
+ Of course, nothing will prevent future LyX releases from being able to
read other formats as well (like gcc error messages for example).
+ This mechanism is necessary to fully explore the literate programming tool's
+ capabilities.
 \layout Section
 
 Algorithm
@@ -89,219 +94,51 @@ main (int argc, char **argv)
 \newline 
 {
 \newline 
-
-\protected_separator 
- if (argc == 2) {
+  if (argc == 2) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- switch (argv[1][0]) {
+    switch (argv[1][0]) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 'n':
+    case 'n':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- <<Scan input for noweb error messages>>
+      <<Scan input for noweb error messages>>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 'x':
+    case 'x':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- <<Scan input for xlc error messages>>
+      <<Scan input for xlc error messages>>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 'a':
+    case 'a':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-<<AIX system using both noweb and xlc>>
+      <<AIX system using both noweb and xlc>>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 's':
+    case 's':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 'b':
+    case 'b':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- <<Solaris and Linux systems using both noweb and gcc>>
+      <<Solaris and Linux systems using both noweb and gcc>>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- case 'g':
+    case 'g':
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- default:
+    default:
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- <<Scan input for gcc error messages>>
+      <<Scan input for gcc error messages>>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+    }
 \newline 
-
-\protected_separator 
- } else {
+  } else {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- <<Scan input for gcc error messages>>
+    <<Scan input for gcc error messages>>
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
 }
 \newline 
@@ -326,43 +163,13 @@ We resort to some global variables to allow access from several different
 
 <<Global variables>>=
 \newline 
-char
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- buffer[200][200];
+char    buffer[200][200];
 \newline 
-int
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- last_buf_line;
+int     last_buf_line;
 \newline 
-int
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- last_err_line;
+int     last_err_line;
 \newline 
-int
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- err_line;
+int     err_line;
 \newline 
 @ 
 \layout Section
@@ -370,7 +177,7 @@ int
 The output format
 \layout Standard
 
-The output format mimics the LaTeX error messages format.
+The output format mimics the TeX error messages format.
  This function prints a number of lines residing in the global variable
  
 \family typewriter 
@@ -378,6 +185,14 @@ buffer
 \family default 
 , a program name and line number.
  There is no special requirement on the input strings, they can be anything.
+\begin_float footnote 
+\layout Standard
+
+This function has been slightly changed from EW's original to make scanning
+ a bit easier with LaTeX::scanLogFile().
+ The test has been added because LyX can crash if empty lines are allowed
+ here --- I can't figure out why! --- BMH
+\end_float 
 \layout Scrap
 
 <<Function bodies>>=
@@ -388,52 +203,36 @@ output_error (int buf_size, int error_line, char *tool)
 \newline 
 {
 \newline 
-
-\protected_separator 
- int
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- i;
+  int     i;
 \newline 
-
-\protected_separator 
-
 \newline 
-
-\protected_separator 
- fprintf(stdout, "! Build Error: ==> %s ==>
+  fprintf(stdout, "! Build Error: ==> %s ==>
 \backslash 
 n", tool);
 \newline 
-
-\protected_separator 
- for (i=0; i<buf_size; i++)
-\newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- fprintf(stdout, "%s", buffer[i]);
-\newline 
-
-\protected_separator 
- fprintf(stdout, " ...
+  fprintf(stdout, " ...
 \backslash 
 n
 \backslash 
 nl.%d ...
 \backslash 
-n
-\backslash 
 n", error_line);
 \newline 
+\newline 
+  for (i=0; i<buf_size; i++)
+\newline 
+    if (strlen(buffer[i]) != 0)
+\newline 
+      fprintf(stdout, "%s", buffer[i]);
+\newline 
+\newline 
+  fprintf(stdout, "
+\backslash 
+n");
+\newline 
 }
 \newline 
 @
@@ -461,37 +260,15 @@ Both noweave and notangle routines, always output one single line for each
 \newline 
 {
 \newline 
-
-\protected_separator 
- last_buf_line = 0;
+  last_buf_line = 0;
 \newline 
-
-\protected_separator 
- while (fgets(buffer[0], 200, stdin)) {
+  while (fgets(buffer[0], 200, stdin)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (noweb_try(0))
+    if (noweb_try(0))
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(1, 0, "noweb");
+      output_error(1, 0, "noweb");
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
 }
 \newline 
@@ -510,53 +287,29 @@ The examination itself is very inefficient.
 \newline 
 char *noweb_msgs[] = {
 \newline 
-
-\protected_separator 
- "couldn't open file",
+  "couldn't open file",
 \newline 
-
-\protected_separator 
- "couldn't open temporary file",
+  "couldn't open temporary file",
 \newline 
-
-\protected_separator 
- "error writing temporary file",
+  "error writing temporary file",
 \newline 
-
-\protected_separator 
- "ill-formed option",
+  "ill-formed option",
 \newline 
-
-\protected_separator 
- "unknown option",
+  "unknown option",
 \newline 
-
-\protected_separator 
- "Bad format sequence",
+  "Bad format sequence",
 \newline 
-
-\protected_separator 
- "Can't open output file",
+  "Can't open output file",
 \newline 
-
-\protected_separator 
- "Can't open temporary file",
+  "Can't open temporary file",
 \newline 
-
-\protected_separator 
- "Capacity exceeded:",
+  "Capacity exceeded:",
 \newline 
-
-\protected_separator 
- "Ignoring unknown option -",
+  "Ignoring unknown option -",
 \newline 
-
-\protected_separator 
- "This can't happen:",
+  "This can't happen:",
 \newline 
-
-\protected_separator 
- "non-numeric line number in" 
+  "non-numeric line number in" 
 \newline 
 };
 \newline 
@@ -564,12 +317,9 @@ char *noweb_msgs[] = {
 \layout Standard
 
 A noweb error message can be any string that contains a matching pair of
- < <
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
+ < <\SpecialChar ~
+\SpecialChar ~
+\SpecialChar ~
 > >, or any of the above strings.
 \layout Scrap
 
@@ -581,161 +331,43 @@ noweb_try (int buf_line)
 \newline 
 {
 \newline 
-
-\protected_separator 
- char
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- *s, *b;
+  char    *s, *b;
 \newline 
-
-\protected_separator 
- int
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- i;
+  int     i;
 \newline 
-
-\protected_separator 
-
 \newline 
-
-\protected_separator 
- b = buffer[buf_line];
+  b = buffer[buf_line];
 \newline 
-
-\protected_separator 
- s = strstr(b, "<<");
+  s = (char *)strstr(b, "<<");
 \newline 
-
-\protected_separator 
- if (s != NULL) {
+  if (s != NULL) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- s = strstr(s+2, ">>");
+    s = (char *)strstr(s+2, ">>");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (s != NULL)
+    if (s != NULL)
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- return 1;
+      return 1;
 \newline 
-
-\protected_separator 
- } else {
+  } else {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- for (i=0; i<12; i++) {
+    for (i=0; i<12; i++) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- s = strstr (b, noweb_msgs[i]);
+      s = (char *)strstr (b, noweb_msgs[i]);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (s != NULL)
+      if (s != NULL)
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-break;
+        break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+    }
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (s != NULL)
+    if (s != NULL)
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- return 1;
+      return 1;
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
-
-\protected_separator 
- return 0;
+  return 0;
 \newline 
 }
 \newline 
@@ -754,43 +386,19 @@ The xlc compiler always outputs one single line for each error found, thus
  line at a time.
 \layout Scrap
 
-<<Scan input for xlc error messages>>=
-\protected_separator 
-
+<<Scan input for xlc error messages>>= 
 \newline 
 {
 \newline 
-
-\protected_separator 
- last_buf_line = 0;
+  last_buf_line = 0;
 \newline 
-
-\protected_separator 
- while (fgets(buffer[last_buf_line], 200, stdin)) {
+  while (fgets(buffer[last_buf_line], 200, stdin)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (xlc_try(0))
+    if (xlc_try(0))
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(1, err_line, "xlc");
+      output_error(1, err_line, "xlc");
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
 }
 \newline 
@@ -819,65 +427,29 @@ xlc_try (int buf_line)
 \newline 
 {
 \newline 
-
-\protected_separator 
- char
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- *s, *t;
+  char    *s, *t;
 \newline 
-
-\protected_separator 
-
 \newline 
-
-\protected_separator 
- t = buffer[buf_line];
+  t = buffer[buf_line];
 \newline 
-
-\protected_separator 
- s = t+1;
+  s = t+1;
 \newline 
-
-\protected_separator 
- while (*s != '"' && *s != ' ' && *s != '
+  while (*s != '"' && *s != ' ' && *s != '
 \backslash 
 0')
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- s++;
+    s++;
 \newline 
-
-\protected_separator 
- if (*t != '"' || *s != '"' || strncmp(s+1, ", line ", 7) != 0)
+  if (*t != '"' || *s != '"' || strncmp(s+1, ", line ", 7) != 0)
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- return 0;
+    return 0;
 \newline 
-
-\protected_separator 
- s += 8;
+  s += 8;
 \newline 
-
-\protected_separator 
- err_line = atoi(s);
+  err_line = atoi(s);
 \newline 
-
-\protected_separator 
- return 1;
+  return 1;
 \newline 
 }
 \newline 
@@ -929,223 +501,53 @@ Every gcc error message contains a string with no space followed by a
 \newline 
 {
 \newline 
-
-\protected_separator 
- char
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- *s, *t;
+  char    *s, *t;
 \newline 
-
-\protected_separator 
-
 \newline 
-
-\protected_separator 
- last_buf_line = 0;
+  last_buf_line = 0;
 \newline 
-
-\protected_separator 
- while (fgets(buffer[last_buf_line], 200, stdin)) {
+  while (fgets(buffer[last_buf_line], 200, stdin)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- /****** Skip lines until I find an error */
+    /****** Skip lines until I find an error */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- s = strpbrk(buffer[last_buf_line], " :");
+    s = (char *)strpbrk(buffer[last_buf_line], " :");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (s == NULL || *s == ' ')
+    if (s == NULL || *s == ' ')
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- continue; /* No gcc error found here */
+      continue; /* No gcc error found here */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- do {
+    do {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-<<gcc error message criteria is to find a "...:999:" or a "...: ">>
+      <<gcc error message criteria is to find a "...:999:" or a "...: ">>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- /****** OK It is an error message, get line number */
+      /****** OK It is an error message, get line number */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- err_line = atoi(s+1);
+      err_line = atoi(s+1);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (last_err_line == 0 || last_err_line == err_line) {
+      if (last_err_line == 0 || last_err_line == err_line) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-last_err_line = err_line;
+        last_err_line = err_line;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-continue; /* It's either a header or a continuation, don't output yet */
+        continue; /* It's either a header or a continuation, don't output
+ yet */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+      }
 \newline 
-
-\protected_separator 
-\protected_separator 
-\protected_separator 
- /****** Completed the scan of one error message, output it to LyX */
+      /****** Completed the scan of one error message, output it to LyX
+ */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- discharge_buffer(1);
+      discharge_buffer(1);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- } while (fgets(buffer[last_buf_line], 200, stdin));
+    } while (fgets(buffer[last_buf_line], 200, stdin));
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-/****** EOF completes the scan of whatever was being scanned */
+  /****** EOF completes the scan of whatever was being scanned */
 \newline 
-
-\protected_separator 
- discharge_buffer(0);
+  discharge_buffer(0);
 \newline 
 }
 \newline 
@@ -1156,35 +558,29 @@ continue; /* It's either a header or a continuation, don't output yet */
 \newline 
 /****** Search first ":" in the error number */
 \newline 
-s = strpbrk(buffer[last_buf_line], " :");
+s = (char *)strpbrk(buffer[last_buf_line], " :");
 \newline 
 last_buf_line++;
 \newline 
 if (s == NULL || *s == ' ') 
 \newline 
-
-\protected_separator 
- <<No gcc error found here, but it might terminate the scanning of a previous
+  <<No gcc error found here, but it might terminate the scanning of a previous
  one>>
 \newline 
 /****** Search second ":" in the error number */
 \newline 
-t = strpbrk(s+1, " :");
+t = (char *)strpbrk(s+1, " :");
 \newline 
 if (t == NULL || *t == ' ')
 \newline 
-
-\protected_separator 
- <<No gcc error found here, but it might terminate the scanning of a previous
+  <<No gcc error found here, but it might terminate the scanning of a previous
  one>>
 \newline 
 /****** Verify if is all digits between ":" */
 \newline 
 if (t != s+1+strspn(s+1, "0123456789")) 
 \newline 
-
-\protected_separator 
- <<No gcc error found here, but it might terminate the scanning of a previous
+  <<No gcc error found here, but it might terminate the scanning of a previous
  one>>
 \newline 
 @
@@ -1195,23 +591,11 @@ if (t != s+1+strspn(s+1, "0123456789"))
 \newline 
 {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-err_line = 0;
+  err_line = 0;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-discharge_buffer(1);
+  discharge_buffer(1);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-continue;
+  continue;
 \newline 
 }
 \newline 
@@ -1241,121 +625,114 @@ discharge_buffer (int save_last)
 \newline 
 {
 \newline 
-
-\protected_separator 
- if (last_err_line != 0) {
+ if (last_err_line != 0) { 
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (save_last != 0) {
+   clean_gcc_messages();
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(last_buf_line-1, last_err_line, "gcc");
+   if (save_last != 0) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- strcpy (buffer[0], buffer[last_buf_line-1]);
+      output_error(last_buf_line-1, last_err_line, "gcc");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- last_err_line = err_line;
+      strcpy (buffer[0], buffer[last_buf_line-1]);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- last_buf_line = 1;
+      last_err_line = err_line;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- } else {
+      last_buf_line = 1;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error (last_buf_line, last_err_line, "gcc");
+    } else { 
 \newline 
+      ++last_buf_line;
+\newline 
+      clean_gcc_messages();
+\newline 
+      output_error(last_buf_line-1, last_err_line, "gcc");
+\newline 
+      last_err_line = 0;
+\newline 
+      last_buf_line = 0;
+\newline 
+    }
+\newline 
+  }
+\newline 
+}
+\newline 
+@
+\layout Scrap
 
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- last_err_line = 0;
+<<Function prototypes>>=
+\newline 
+void discharge_buffer (int save_last);
 \newline 
+@
+\layout Standard
 
-\protected_separator 
+The next function 
+\begin_inset Quotes eld
+\end_inset 
 
-\protected_separator 
+cleans
+\begin_inset Quotes erd
+\end_inset 
 
-\protected_separator 
+ superfluous information from gcc messages, namely the name of the noweb
+ file and the line number of the Error.
+\begin_float footnote 
+\layout Standard
 
-\protected_separator 
+More could be done.
+ For instance, some way of distinguishing between gcc Errors and Warnings
+ should be devised.
+\end_float 
+\layout Scrap
 
-\protected_separator 
- last_buf_line = 0;
+<<Function bodies>>=
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+void
 \newline 
-
-\protected_separator 
- }
+clean_gcc_messages ()
+\newline 
+{
+\newline 
+  int index;
+\newline 
+  char search [30]; 
+\newline 
+  char *tail, *head; 
+\newline 
+  int search_len = sprintf(search, ".nw:%d:", last_err_line);
+\newline 
+  
+\newline 
+  for (index = 0; index < last_buf_line-1; index++) {
+\newline 
+    tail = (char *)strstr (buffer[index], search);
+\newline 
+    if ( tail == NULL) {
+\newline 
+       tail = (char *) strstr (buffer[index], ".nw:");
+\newline 
+       if (tail) {
+\newline 
+          tail += 4;
+\newline 
+       }
+\newline 
+    } else {
+\newline 
+       tail += search_len;
+\newline 
+    }
+\newline 
+    if (tail != NULL) {
+\newline 
+       head = buffer[index];
+\newline 
+       while (*(head++) = *(tail++));
+\newline 
+    }
+\newline 
+  }
 \newline 
 }
 \newline 
@@ -1364,7 +741,7 @@ discharge_buffer (int save_last)
 
 <<Function prototypes>>=
 \newline 
-void discharge_buffer (int save_last);
+void clean_gcc_messages ();
 \newline 
 @
 \layout Standard
@@ -1378,57 +755,19 @@ To combine the scan of noweb error messages and xlc error messages is very
 \newline 
 {
 \newline 
-
-\protected_separator 
- last_buf_line = 0;
+  last_buf_line = 0;
 \newline 
-
-\protected_separator 
- while (fgets(buffer[0], 200, stdin)) {
+  while (fgets(buffer[0], 200, stdin)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (noweb_try(0))
+    if (noweb_try(0))
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(1, 0, "noweb");
+      output_error(1, 0, "noweb");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- else if (xlc_try(0))
+    else if (xlc_try(0))
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(1, err_line, "xlc");
+      output_error(1, err_line, "xlc");
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
 }
 \newline 
@@ -1436,8 +775,8 @@ To combine the scan of noweb error messages and xlc error messages is very
 \layout Standard
 
 To combine the scan of noweb error messages and gcc error messages is simple
- if we realize that it is not possible to find a noweb error message
in the middle of a gcc error message.
+ if we realize that it is not possible to find a noweb error message in
+ the middle of a gcc error message.
  So we just repeat the gcc procedure and test for noweb error messages in
  the beginning of the scan:
 \layout Scrap
@@ -1446,263 +785,61 @@ To combine the scan of noweb error messages and gcc error messages is simple
 \newline 
 {
 \newline 
-
-\protected_separator 
- char
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- *s, *t;
+  char    *s, *t;
 \newline 
-
-\protected_separator 
-
 \newline 
-
-\protected_separator 
- last_buf_line = 0;
+  last_buf_line = 0;
 \newline 
-
-\protected_separator 
- while (fgets(buffer[last_buf_line], 200, stdin)) {
+  while (fgets(buffer[last_buf_line], 200, stdin)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- /****** Skip lines until I find an error */
+    /****** Skip lines until I find an error */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (last_buf_line == 0 && noweb_try(0)) {
+    if (last_buf_line == 0 && noweb_try(0)) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- output_error(1, 0, "noweb");
+      output_error(1, 0, "noweb");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- continue;
+      continue;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+    }
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- s = strpbrk(buffer[last_buf_line], " :");
+    s = (char *)strpbrk(buffer[last_buf_line], " :");
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (s == NULL || *s == ' ')
+    if (s == NULL || *s == ' ')
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- continue; /* No gcc error found here */
+      continue; /* No gcc error found here */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- do {
+    do {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-<<gcc error message criteria is to find a "...:999:" or a "...: ">>
+      <<gcc error message criteria is to find a "...:999:" or a "...: ">>
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- /****** OK It is an error, get line number */
+      /****** OK It is an error, get line number */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- err_line = atoi(s+1);
+      err_line = atoi(s+1);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- if (last_err_line == 0 || last_err_line == err_line) {
+      if (last_err_line == 0 || last_err_line == err_line) {
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-last_err_line = err_line;
+        last_err_line = err_line;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-continue; /* It's either a header or a continuation, don't output yet */
+        continue; /* It's either a header or a continuation, don't output
+ yet */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- }
+      }
 \newline 
-
-\protected_separator 
-\protected_separator 
-\protected_separator 
- /****** Completed the scan of one error message, output it to LyX */
+      /****** Completed the scan of one error message, output it to LyX
+ */
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- discharge_buffer(1);
+      discharge_buffer(1);
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- break;
+      break;
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-
-\protected_separator 
- } while (fgets(buffer[last_buf_line], 200, stdin));
+    } while (fgets(buffer[last_buf_line], 200, stdin));
 \newline 
-
-\protected_separator 
- }
+  }
 \newline 
-
-\protected_separator 
-
-\protected_separator 
-/****** EOF completes the scan of whatever was being scanned */
+  /****** EOF completes the scan of whatever was being scanned */
 \newline 
-
-\protected_separator 
- discharge_buffer(0);
+  discharge_buffer(0);
 \newline 
 }
 \newline 
@@ -1716,17 +853,9 @@ Wrapping the code into a file
 \newline 
 #include <stdio.h>
 \newline 
-#include <strings.h> 
-\protected_separator 
-\protected_separator 
-\protected_separator 
+#include <strings.h>       
 \newline 
-
-\protected_separator 
-
 \newline 
 <<Global variables>>
 \newline 
@@ -1794,9 +923,3 @@ build-script
 \newline 
 notangle -Rbuild-script $1 | sh
 \the_end
-
-
-
-
-
-
index e305bd0b659e4449e3a8246597cf4329908ee25d..d792cb0ba5a084a6400a37e9991d0fd1d6ca86a8 100644 (file)
@@ -281,6 +281,7 @@ bool BufferView::open_new_inset(UpdatableInset * new_inset)
        text->CursorLeft(this);
        update(BufferView::SELECT|BufferView::FITCUR|BufferView::CHANGE);
        new_inset->Edit(this, 0, 0, 0);
+       return true;
 }
 
 /* This is also a buffer property (ale) */
index 7443d01cfd1ad6d78464dcc0ede39a3c7c32d462..134d6d310e8876cf75e52b1b26e0a44019bdf92f 100644 (file)
@@ -51,6 +51,7 @@ int Literate::weave(TeXErrors & terr, MiniBuffer * minib)
         string tmp1, tmp2;
         int ret1, ret2;
         Systemcalls one, two;
+       string logfile = OnlyFilename(ChangeExtension(file, ".log"));
 
         // The class LaTeX does not know the temp path.
         bufferlist.updateIncludedTeXfiles(GetCWD());
@@ -62,17 +63,18 @@ int Literate::weave(TeXErrors & terr, MiniBuffer * minib)
         // Run the literate program to convert \literate_extension file to .tex file
         //
         tmp1 = literate_cmd + " < " + litfile + " > " + file + " 2> " + litfile + ".out";
-        tmp2 = literate_filter + " < " + litfile + ".out" + " > " + litfile + ".log";
+        tmp2 = literate_filter + " < " + litfile + ".out" + " > " + logfile;
         ret1 = one.startscript(Systemcalls::System, tmp1);
         ret2 = two.startscript(Systemcalls::System, tmp2);
         lyxerr.debug() << "LITERATE {" << tmp1 << "} {" << tmp2 << "}" << endl;
-       scanres = scanLiterateLogFile();
+
+       scanres = scanLogFile(terr);
        if (scanres & Literate::ERRORS) return scanres; // return on literate error
        return run(terr, minib);
 }
 
 
-int Literate::build(TeXErrors & /*terr*/, MiniBuffer * minib)
+int Literate::build(TeXErrors & terr, MiniBuffer * minib)
         // We know that this function will only be run if the lyx buffer
         // has been changed. 
 {
@@ -81,6 +83,8 @@ int Literate::build(TeXErrors & /*terr*/, MiniBuffer * minib)
         string tmp1, tmp2;
         int ret1, ret2;
         Systemcalls one, two;
+       string logfile = OnlyFilename(ChangeExtension(file, ".log"));
+
         
         // The class LaTeX does not know the temp path.
         bufferlist.updateIncludedTeXfiles(GetCWD());
@@ -92,69 +96,12 @@ int Literate::build(TeXErrors & /*terr*/, MiniBuffer * minib)
         // Run the build program
         //
         tmp1 = build_cmd + ' ' + litfile + " > " + litfile + ".out 2>&1";
-        tmp2 = build_filter + " < " + litfile + ".out" + " > " + litfile + ".log";
+        tmp2 = build_filter + " < " + litfile + ".out" + " > " + logfile;
         ret1 = one.startscript(Systemcalls::System, tmp1);
         ret2 = two.startscript(Systemcalls::System, tmp2);
-        scanres = scanBuildLogFile();
+
+       scanres = scanLogFile(terr);
         lyxerr[Debug::LATEX] << "Done." << endl;
 
         return scanres;
 }
-
-
-int Literate::scanLiterateLogFile()
-{
-        string token;
-        int retval = NO_ERRORS;
-        
-        string tmp = litfile + ".log";
-        
-        ifstream ifs(tmp.c_str());
-       while (getline(ifs, token)) {
-                lyxerr[Debug::LATEX] << token << endl;
-                
-                if (prefixIs(token, "Build Warning:")) {
-                        // Here shall we handle different
-                        // types of warnings
-                        retval |= LATEX_WARNING;
-                        lyxerr[Debug::LATEX] << "Build Warning." << endl;
-                } else if (prefixIs(token, "! Build Error:")) {
-                        // Here shall we handle different
-                        // types of errors
-                        retval |= LATEX_ERROR;
-                        lyxerr[Debug::LATEX] << "Build Error." << endl;
-                        // this is not correct yet
-                        ++num_errors;
-                }
-        }       
-        return retval;
-}
-
-
-int Literate::scanBuildLogFile()
-{
-        string token;
-        int retval = NO_ERRORS;
-        string tmp = litfile + ".log";
-        
-        ifstream ifs(tmp.c_str());
-       while (getline(ifs, token)) {
-                lyxerr[Debug::LATEX] << token << endl;
-                
-                if (prefixIs(token, "Build Warning:")) {
-                        // Here shall we handle different
-                        // types of warnings
-                        retval |= LATEX_WARNING;
-                        lyxerr[Debug::LATEX] << "Build Warning." << endl;
-                } else if (prefixIs(token, "! Build Error:")) {
-                        // Here shall we handle different
-                        // types of errors
-                        retval |= LATEX_ERROR;
-                        lyxerr[Debug::LATEX] << "Build Error." << endl;
-                        // this is not correct yet
-                        ++num_errors;
-                }
-        }       
-        return retval;
-}
index 2b65841d4e5ae27bb17368c9c30c0038c6940ca9..9027db10d03c2f2e41ccf793f28ea4e1a432d400 100644 (file)
@@ -33,12 +33,6 @@ public:
         /// runs literate and build
         int build(TeXErrors &, MiniBuffer *);
 private:
-        ///
-        int scanLiterateLogFile();
-
-        ///
-        int scanBuildLogFile();
-
         ///
         string litfile;
         
@@ -56,3 +50,5 @@ private:
 };
 
 #endif
+
+
index 272e4ef5e823f973aad06052477500a6593a2f2c..29c206df516b4eabb3e9f72ca013a2f6b8f9a920 100644 (file)
@@ -24,8 +24,11 @@ using SigC::slot;
 #endif
 
 C_RETURNCB(FormTabular,  WMHideCB)
-C_GENERICCB(FormTabular, TabularCloseCB)
-C_GENERICCB(FormTabular, TabularInputCB)
+C_GENERICCB(FormTabular, CloseCB)
+C_GENERICCB(FormTabular, InputCB)
+C_GENERICCB(FormTabular, OKCB)
+C_GENERICCB(FormTabular, ApplyCB)
+C_GENERICCB(FormTabular, CancelCB)
 
 
 FormTabular::FormTabular(LyXView * lv, Dialogs * d)
@@ -194,14 +197,14 @@ int FormTabular::WMHideCB(FL_FORM * form, void *)
 }
 
 
-void FormTabular::TabularCloseCB(FL_OBJECT * ob, long)
+void FormTabular::CloseCB(FL_OBJECT * ob, long)
 {
     FormTabular * pre = static_cast<FormTabular*>(ob->form->u_vdata);
     pre->hide();
 }
 
 
-void FormTabular::TabularInputCB(FL_OBJECT * ob, long)
+void FormTabular::InputCB(FL_OBJECT * ob, long)
 {
     FormTabular * pre = static_cast<FormTabular*>(ob->form->u_vdata);
     pre->input();
@@ -404,7 +407,7 @@ void FormTabular::apply_create()
 }
 
 
-void FormTabular::TabularOKCB(FL_OBJECT * ob, long)
+void FormTabular::OKCB(FL_OBJECT * ob, long)
 {
     FormTabular * pre = (FormTabular*)ob->form->u_vdata;
     pre->apply_create();
@@ -412,15 +415,17 @@ void FormTabular::TabularOKCB(FL_OBJECT * ob, long)
 }
 
 
-void FormTabular::TabularApplyCB(FL_OBJECT * ob, long)
+void FormTabular::ApplyCB(FL_OBJECT * ob, long)
 {
     FormTabular * pre = (FormTabular*)ob->form->u_vdata;
     pre->apply_create();
 }
 
 
-void FormTabular::TabularCancelCB(FL_OBJECT * ob, long)
+void FormTabular::CancelCB(FL_OBJECT * ob, long)
 {
     FormTabular * pre = (FormTabular*)ob->form->u_vdata;
     pre->hide_create();
 }
+
+
index 63b9e9eb64f9186d737b84c04da126767dd58f4d..e5def09932ee156afca67f9a0c7f01b87d19c072 100644 (file)
@@ -43,11 +43,11 @@ public:
     /**@name Real per-instance Callback Methods */
     //@{
     static  int WMHideCB(FL_FORM *, void *);
-    static void TabularCloseCB(FL_OBJECT *, long);
-    static void TabularOKCB(FL_OBJECT *, long);
-    static void TabularCancelCB(FL_OBJECT *, long);
-    static void TabularApplyCB(FL_OBJECT *, long);
-    static void TabularInputCB(FL_OBJECT *, long);
+    static void CloseCB(FL_OBJECT *, long);
+    static void OKCB(FL_OBJECT *, long);
+    static void CancelCB(FL_OBJECT *, long);
+    static void ApplyCB(FL_OBJECT *, long);
+    static void InputCB(FL_OBJECT *, long);
     //@}
 
 private:
index 7d4e7bdb849276fc14ba471522f1450d665bdc36..0a58769abf9547a0392293bfe278d2139bed81a7 100644 (file)
@@ -21,7 +21,7 @@ FD_form_tabular * FormTabular::build_tabular()
     fl_set_object_resize(obj, FL_RESIZE_ALL);
   fdui->button_close = obj = fl_add_button(FL_NORMAL_BUTTON, 395, 300, 100, 30, idex(_("Close|#C")));fl_set_button_shortcut(obj, scex(_("Close|#C")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularCloseCB, 0);
+    fl_set_object_callback(obj, C_FormTabularCloseCB, 0);
   fdui->input_tabular_column = obj = fl_add_input(FL_NORMAL_INPUT, 15, 300, 60, 30, _("Column"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_TOP_LEFT);
@@ -52,26 +52,26 @@ FD_form_tabular_options * FormTabular::build_tabular_options()
     fl_set_object_color(obj, FL_COL1, FL_COL1);
   fdui->button_append_column = obj = fl_add_button(FL_NORMAL_BUTTON, 10, 40, 120, 30, idex(_("Append Column|#A")));fl_set_button_shortcut(obj, scex(_("Append Column|#A")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->button_delete_column = obj = fl_add_button(FL_NORMAL_BUTTON, 140, 40, 120, 30, idex(_("Delete Column|#O")));fl_set_button_shortcut(obj, scex(_("Delete Column|#O")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->button_append_row = obj = fl_add_button(FL_NORMAL_BUTTON, 10, 70, 120, 30, idex(_("Append Row|#p")));fl_set_button_shortcut(obj, scex(_("Append Row|#p")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->button_delete_row = obj = fl_add_button(FL_NORMAL_BUTTON, 140, 70, 120, 30, idex(_("Delete Row|#w")));fl_set_button_shortcut(obj, scex(_("Delete Row|#w")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->button_set_borders = obj = fl_add_button(FL_NORMAL_BUTTON, 10, 10, 120, 30, idex(_("Set Borders|#S")));fl_set_button_shortcut(obj, scex(_("Set Borders|#S")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->button_unset_borders = obj = fl_add_button(FL_NORMAL_BUTTON, 140, 10, 120, 30, idex(_("Unset Borders|#U")));fl_set_button_shortcut(obj, scex(_("Unset Borders|#U")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_longtable = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 280, 30, 90, 25, _("Longtable"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_rotate_tabular = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 280, 55, 90, 25, idex(_("Rotate 90°|#9")));fl_set_button_shortcut(obj, scex(_("Rotate 90°|#9")), 1);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_text(FL_NORMAL_TEXT, 285, 10, 100, 20, _("Spec. Table"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
@@ -102,19 +102,19 @@ FD_form_column_options * FormTabular::build_column_options()
   fdui->radio_border_top = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 85, 45, 25, 25, idex(_("Top|#t")));fl_set_button_shortcut(obj, scex(_("Top|#t")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_TOP_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_bottom = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 85, 75, 25, 25, idex(_("Bottom|#b")));fl_set_button_shortcut(obj, scex(_("Bottom|#b")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_BOTTOM_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_left = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 65, 60, 25, 25, idex(_("Left|#l")));fl_set_button_shortcut(obj, scex(_("Left|#l")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_right = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 105, 60, 25, 25, idex(_("Right|#r")));fl_set_button_shortcut(obj, scex(_("Right|#r")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_RIGHT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_frame(FL_ENGRAVED_FRAME, 200, 20, 130, 105, "");
     fl_set_object_color(obj, FL_COL1, FL_COL1);
   obj = fl_add_text(FL_NORMAL_TEXT, 205, 10, 115, 20, _("H. Alignment"));
@@ -123,27 +123,27 @@ FD_form_column_options * FormTabular::build_column_options()
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->radio_align_left = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 205, 30, 110, 25, idex(_("Left|#e")));fl_set_button_shortcut(obj, scex(_("Left|#e")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_align_right = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 205, 55, 115, 25, idex(_("Right|#i")));fl_set_button_shortcut(obj, scex(_("Right|#i")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_align_center = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 205, 80, 115, 25, idex(_("Center|#c")));fl_set_button_shortcut(obj, scex(_("Center|#c")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->input_column_width = obj = fl_add_input(FL_NORMAL_INPUT, 375, 150, 95, 30, _("Width of column:"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_frame(FL_ENGRAVED_FRAME, 340, 20, 130, 105, "");
     fl_set_object_color(obj, FL_COL1, FL_COL1);
   fdui->radio_valign_top = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 345, 30, 110, 25, idex(_("Top|#p")));fl_set_button_shortcut(obj, scex(_("Top|#p")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_valign_center = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 345, 55, 115, 25, idex(_("Center|#n")));fl_set_button_shortcut(obj, scex(_("Center|#n")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_valign_bottom = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 345, 80, 115, 25, idex(_("Bottom|#o")));fl_set_button_shortcut(obj, scex(_("Bottom|#o")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_text(FL_NORMAL_TEXT, 345, 10, 115, 20, _("V. Alignment"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
@@ -153,7 +153,7 @@ FD_form_column_options * FormTabular::build_column_options()
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
   fdui->input_special_alignment = obj = fl_add_input(FL_NORMAL_INPUT, 30, 150, 200, 30, "");
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_text(FL_NORMAL_TEXT, 25, 130, 170, 20, _("Special Column Alignment"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
@@ -199,58 +199,58 @@ FD_form_cell_options * FormTabular::build_cell_options()
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->radio_multicolumn = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 10, 25, 145, 25, idex(_("Multicolumn|#M")));fl_set_button_shortcut(obj, scex(_("Multicolumn|#M")), 1);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_linebreak_cell = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 10, 50, 145, 25, idex(_("Linebreaks|#N")));fl_set_button_shortcut(obj, scex(_("Linebreaks|#N")), 1);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_rotate_cell = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 10, 75, 145, 25, _("Rotate 90°"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_frame(FL_ENGRAVED_FRAME, 165, 15, 305, 85, "");
     fl_set_object_color(obj, FL_COL1, FL_COL1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
   fdui->input_special_multialign = obj = fl_add_input(FL_NORMAL_INPUT, 175, 30, 280, 30, "");
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_text(FL_NORMAL_TEXT, 170, 5, 290, 20, _("Special Multicolumn Alignment"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->input_mcolumn_width = obj = fl_add_input(FL_NORMAL_INPUT, 360, 65, 95, 30, _("Width of multi-column:"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_top = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 75, 135, 25, 25, idex(_("Top|#t")));fl_set_button_shortcut(obj, scex(_("Top|#t")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_TOP_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_bottom = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 75, 165, 25, 25, idex(_("Bottom|#b")));fl_set_button_shortcut(obj, scex(_("Bottom|#b")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_BOTTOM_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_left = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 55, 150, 25, 25, idex(_("Left|#l")));fl_set_button_shortcut(obj, scex(_("Left|#l")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_border_right = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 95, 150, 25, 25, idex(_("Right|#r")));fl_set_button_shortcut(obj, scex(_("Right|#r")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_RIGHT);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_align_left = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 195, 120, 110, 25, idex(_("Left|#e")));fl_set_button_shortcut(obj, scex(_("Left|#e")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_align_right = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 195, 145, 115, 25, idex(_("Right|#i")));fl_set_button_shortcut(obj, scex(_("Right|#i")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_align_center = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 195, 170, 115, 25, idex(_("Center|#c")));fl_set_button_shortcut(obj, scex(_("Center|#c")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_valign_top = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 340, 120, 110, 25, idex(_("Top|#p")));fl_set_button_shortcut(obj, scex(_("Top|#p")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_valign_center = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 340, 145, 115, 25, idex(_("Center|#n")));fl_set_button_shortcut(obj, scex(_("Center|#n")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_valign_bottom = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 340, 170, 115, 25, idex(_("Bottom|#o")));fl_set_button_shortcut(obj, scex(_("Bottom|#o")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fl_end_form();
 
   fdui->form_cell_options->fdui = fdui;
@@ -273,25 +273,25 @@ FD_form_longtable_options * FormTabular::build_longtable_options()
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->radio_lt_firsthead = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 15, 30, 90, 25, _("First Head"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_lt_head = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 15, 60, 90, 25, _("Head"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_frame(FL_ENGRAVED_FRAME, 130, 20, 100, 75, "");
   obj = fl_add_text(FL_NORMAL_TEXT, 135, 10, 85, 20, _("Footer"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->radio_lt_foot = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 135, 30, 90, 25, _("Foot"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fdui->radio_lt_lastfoot = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 135, 60, 90, 25, _("Last Foot"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   obj = fl_add_frame(FL_ENGRAVED_FRAME, 245, 20, 95, 75, "");
   obj = fl_add_text(FL_NORMAL_TEXT, 250, 10, 85, 20, _("Special"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     fl_set_object_lstyle(obj, FL_BOLD_STYLE);
   fdui->radio_lt_newpage = obj = fl_add_checkbutton(FL_PUSH_BUTTON, 250, 30, 90, 25, _("New Page"));
-    fl_set_object_callback(obj, TabularInputCB, 0);
+    fl_set_object_callback(obj, C_FormTabularInputCB, 0);
   fl_end_form();
 
   fdui->form_longtable_options->fdui = fdui;
@@ -310,13 +310,13 @@ FD_form_create_tabular * FormTabular::build_create_tabular()
   obj = fl_add_box(FL_UP_BOX, 0, 0, 310, 130, "");
   fdui->button_ok = obj = fl_add_button(FL_RETURN_BUTTON, 10, 90, 90, 30, _("OK"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularOKCB, 0);
+    fl_set_object_callback(obj, C_FormTabularOKCB, 0);
   fdui->button_apply = obj = fl_add_button(FL_NORMAL_BUTTON, 110, 90, 90, 30, idex(_("Apply|#A")));fl_set_button_shortcut(obj, scex(_("Apply|#A")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularApplyCB, 0);
+    fl_set_object_callback(obj, C_FormTabularApplyCB, 0);
   fdui->button_cancel = obj = fl_add_button(FL_NORMAL_BUTTON, 210, 90, 90, 30, idex(_("Cancel|^[")));fl_set_button_shortcut(obj, scex(_("Cancel|^[")), 1);
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
-    fl_set_object_callback(obj, TabularCancelCB, 0);
+    fl_set_object_callback(obj, C_FormTabularCancelCB, 0);
   fdui->slider_columns = obj = fl_add_valslider(FL_HOR_SLIDER, 80, 50, 220, 30, _("Columns"));
     fl_set_object_lsize(obj, FL_NORMAL_SIZE);
     fl_set_object_lalign(obj, FL_ALIGN_LEFT);
index 2560e8cf7193a827e23e0f36c9cf2e868bab8c29..f25187ab73de243d521f709b476b293b4a136654 100644 (file)
@@ -1,22 +1,22 @@
-/** Header file generated with fdesign on Tue Jul 11 16:33:31 2000.**/
+/** Header file generated with fdesign on Wed Jul 12 15:19:16 2000.**/
 
 #ifndef FD_form_tabular_h_
 #define FD_form_tabular_h_
 
 /** Callbacks, globals and object handlers **/
-extern  "C" void TabularCloseCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularCloseCB(FL_OBJECT *, long);
 
-extern  "C" void TabularInputCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularInputCB(FL_OBJECT *, long);
 
-extern  "C" void TabularInputCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularInputCB(FL_OBJECT *, long);
 
-extern  "C" void TabularInputCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularInputCB(FL_OBJECT *, long);
 
-extern  "C" void TabularInputCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularInputCB(FL_OBJECT *, long);
 
-extern  "C" void TabularOKCB(FL_OBJECT *, long);
-extern  "C" void TabularApplyCB(FL_OBJECT *, long);
-extern  "C" void TabularCancelCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularOKCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularApplyCB(FL_OBJECT *, long);
+extern  "C" void C_FormTabularCancelCB(FL_OBJECT *, long);
 
 
 /**** Forms and Objects ****/
index 5c419f8fa241fe77a2554ed6b9b11460759bb836..2c8268c1c329dabbc9e0028d402eb0b2e9f87d95 100644 (file)
@@ -64,7 +64,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_close
-callback: TabularCloseCB
+callback: C_FormTabularCloseCB
 argument: 0
 
 --------------------
@@ -178,7 +178,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_append_column
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -196,7 +196,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_delete_column
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -214,7 +214,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_append_row
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -232,7 +232,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_delete_row
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -250,7 +250,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_set_borders
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -268,7 +268,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_unset_borders
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -286,7 +286,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_longtable
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -304,7 +304,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_rotate_tabular
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -400,7 +400,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_top
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -418,7 +418,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_bottom
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -436,7 +436,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_left
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -454,7 +454,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_right
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -508,7 +508,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_left
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -526,7 +526,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_right
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -544,7 +544,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_center
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -562,7 +562,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: input_column_width
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -598,7 +598,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_top
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -616,7 +616,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_center
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -634,7 +634,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_bottom
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -688,7 +688,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: input_special_alignment
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -892,7 +892,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_multicolumn
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -910,7 +910,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_linebreak_cell
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -928,7 +928,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_rotate_cell
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -964,7 +964,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: input_special_multialign
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1000,7 +1000,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: input_mcolumn_width
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1018,7 +1018,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_top
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1036,7 +1036,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_bottom
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1054,7 +1054,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_left
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1072,7 +1072,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_border_right
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1090,7 +1090,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_left
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1108,7 +1108,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_right
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1126,7 +1126,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_align_center
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1144,7 +1144,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_top
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1162,7 +1162,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_center
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1180,7 +1180,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_valign_bottom
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 =============== FORM ===============
@@ -1258,7 +1258,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_lt_firsthead
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1276,7 +1276,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_lt_head
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1330,7 +1330,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_lt_foot
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1348,7 +1348,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_lt_lastfoot
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 --------------------
@@ -1402,7 +1402,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: radio_lt_newpage
-callback: TabularInputCB
+callback: C_FormTabularInputCB
 argument: 0
 
 =============== FORM ===============
@@ -1444,7 +1444,7 @@ shortcut: ^M
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_ok
-callback: TabularOKCB
+callback: C_FormTabularOKCB
 argument: 0
 
 --------------------
@@ -1462,7 +1462,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_apply
-callback: TabularApplyCB
+callback: C_FormTabularApplyCB
 argument: 0
 
 --------------------
@@ -1480,7 +1480,7 @@ shortcut:
 resize: FL_RESIZE_ALL
 gravity: FL_NoGravity FL_NoGravity
 name: button_cancel
-callback: TabularCancelCB
+callback: C_FormTabularCancelCB
 argument: 0
 
 --------------------
index ca8e7a9c3683da47209556e2d71dceed2ed7f32d..c957576010ace2e07347eb5a63d1be0fa229fef6 100644 (file)
@@ -47,7 +47,7 @@ using std::endl;
 
 #define cellstart(p) ((p % 2) == 0)
 
-//#define USE_NEW_LAYOUT 1
+#define USE_NEW_LAYOUT 1
 
 InsetTabular::InsetTabular(Buffer * buf, int rows, int columns)
 {