]> git.saurik.com Git - wxWidgets.git/commitdiff
Changes to detect unresolved references (REF NOT FOUND) during HTML conversion
authorGeorge Tasker <gtasker@allenbrook.com>
Fri, 25 May 2001 13:02:53 +0000 (13:02 +0000)
committerGeorge Tasker <gtasker@allenbrook.com>
Fri, 25 May 2001 13:02:53 +0000 (13:02 +0000)
Filenames with underscores are no longer reported as errant uses of '_' character
Minor GUI display tweeks.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10326 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

utils/tex2rtf/src/htmlutil.cpp
utils/tex2rtf/src/rtfutils.cpp
utils/tex2rtf/src/tex2any.cpp

index f95065016dc2f40484944bb07df8db154a1b4c22..c91ca52c9f4c7696c2d34225ce95a6970ca48ba0 100644 (file)
@@ -1907,6 +1907,9 @@ bool HTMLOnArgument(int macroId, int arg_no, bool start)
             if (helpRefText)
               TraverseChildrenFromChunk(helpRefText);
             TexOutput(" (REF NOT FOUND)");
+            wxString errBuf;
+            errBuf.Printf("Warning: unresolved reference '%s'", refName);
+            OnInform((char *)errBuf.c_str());
           }
         }
         else TexOutput("??");
index c3a3968f1b9eeb897b550122e9595f2856ab59b6..3a596413a86cd2d8fa6b9f4bcfca34da06891161 100644 (file)
@@ -3375,7 +3375,7 @@ bool RTFOnArgument(int macroId, int arg_no, bool start)
                   else
                   {
                     TexOutput("??");
-                    sprintf(buf, "Warning: unresolved reference %s.", refName);
+                    sprintf(buf, "Warning: unresolved reference '%s'", refName);
                     OnInform(buf);
                   }
                 }
index d689c9e17e877acd430403050b1cc8bd0749ed25..4f63fba613911daad23a808dca9463db74a953bf 100644 (file)
@@ -600,7 +600,8 @@ bool read_a_line(char *buf)
                    errBuf.Printf("An underscore ('_') was detected at line %lu inside file %s that may need a '\\' before it.",LineNumbers[CurrentInputIndex], (const char*) currentFileName.c_str());
                    OnError((char *)errBuf.c_str());
                 }
-                else if ((buf[bufIndex-1] != '\\') && (buf[0] != '%'))  // If it is a comment line, then no warnings
+                else if ((buf[bufIndex-1] != '\\') && (buf[0] != '%') &&  // If it is a comment line, then no warnings
+                         (strncmp(buf, "\\input", 6))) // do not report filenames that have underscores in them
                 {
                    wxString errBuf;
                    errBuf.Printf("An underscore ('_') was detected at line %lu inside file %s that may need a '\\' before it.",LineNumbers[CurrentInputIndex], (const char*) currentFileName.c_str());
@@ -3133,7 +3134,7 @@ bool DefaultOnArgument(int macroId, int arg_no, bool start)
         {
           char buf[300];
           TexOutput("??", TRUE);
-          sprintf(buf, "Warning: unresolved reference %s.", refName); 
+          sprintf(buf, "Warning: unresolved reference '%s'", refName); 
           OnInform(buf);
         }
       }