help-texinfo
[Top][All Lists]
Advanced

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

[help-texinfo] SOLVED - Re: makeinfo: error messages for processing nest


From: Simon Sobisch
Subject: [help-texinfo] SOLVED - Re: makeinfo: error messages for processing nested entries (table->item->enumeration)
Date: Mon, 7 Aug 2017 22:46:32 +0200
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

Thank you very much!

Am 07.08.2017 um 19:35 schrieb Gavin Smith:
> On Mon, Aug 07, 2017 at 12:18:40AM +0200, Simon Sobisch wrote:
>> makeinfo produces error messages like
>>
>> ./1.texi:488: @item outside of table or list
>> ./1.texi:501: unmatched address@hidden table'
>>
>> for the following part
>>
>> @p @table @asis                      <--- line 475
>> @p @item Color
>> @p [...]  The eight colors, by number, with the constant names defined
>> in screenio.cpy, are as follows:
>> @enumerate 0
>> @p @item Black: COB-COLOR-BLACK
>> @p @item Blue: COB-COLOR-BLUE
>> @p @item Green: COB-COLOR-GREEN
>> @p @item Cyan (Turquoise): COB-COLOR-CYAN
>> @p @item Red: COB-COLOR-RED
>> @p @item Magenta: COB-COLOR-MAGENTA
>> @p @item Yellow: COB-COLOR-YELLOW
>> @p @item White: COB-COLOR-WHITE
>> @end enumerate
>> @item Text Brightness                 <--- line 488
>> @p [...]
>> @item [...]
>> @p [...]
>> @end table                            <--- line 501
>>
>> As far as I see the @item in line 488 and the @end table belong to the
>> @table in line 475.
>> This is the way it can be seen in the PDF generated by texi2pdf, too.
> 
> It appears to be related to the use of the macro @p.
> 
> I found a definition in Macros.texi at 
> https://svn.code.sf.net/p/open-cobol/code/external-doc/guide/
> 
> @comment +-------------------------------------------------------------------+
> @comment | MACRO: p                                                          |
> @comment |                                                                   |
> @comment | Begin a new paragraph in a manner appropriate for either INFO or  |
> @comment | TeX.                                                              |
> @comment +-------------------------------------------------------------------+
> 
> @macro p
> @ifinfo
> @sp 1
> @end ifinfo
> @iftex
> @sp 0.5
> @end iftex
> @end macro
> 
> I haven't checked for sure, but what is likely happening is that the 
> macro is being expanded as
> 
> @sp 1 @table @asis
> 
> which may be wrong as @table should begin a new line.
> 
> One thing you could try is changing the macro definition, like:
> 
> @macro p
> @ifinfo
> @sp 1
> 
> @end ifinfo
> @iftex
> @sp 0.5
> 
> @end iftex
> @end macro
> 
> Then it would be expanded as
> 
> @sp 1
> @table @asis
> 
> Possibly the macros worked with older versions of makeinfo, but there 
> are a few incompatibilities around the use of macros.
> 

I did not read the "must be on a new line" part. As @p is used all over
the place and the files are changed by others too I've gone the "fix
macro approach" (there were similar issues with much less occurrences
which I've fixed directly by inserting a line break).

I've changed the macro the following way and it works fine now!

  @comment
+-------------------------------------------------------------------+
  @comment | MACRO: p
      |
  @comment |
      |
  @comment | Begin a new paragraph in a manner appropriate for either
INFO or  |
  @comment | TeX.
      |
 address@hidden |
      |
 address@hidden | NOTE: the additional line break before @end macro is
necessary!!! |
  @comment
+-------------------------------------------------------------------+
  @macro p
  @ifinfo
  @sp 1
  @end ifinfo
  @iftex
  @sp 0.5
  @end iftex
 +
  @end macro

I'm going on to fixing the other issues that are in the tex files...

Simon



reply via email to

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