LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Blogs > astrogeek
User Name
Password

Notices


Rate this Entry

Outline Input Example

Posted 11-15-2021 at 03:32 AM by astrogeek

Following is an example input file for the post Flex Based Outline Generator.

Copy the text below into a file named example.txt in your build directory and pass it as input to the application described in the above linked post.

Code:
##########################################
# Example Outline Specification          #
# Outlines operation of outline parser   #
##########################################

.tcOutline Generator Outline
.tl

#disable ordering prefixes for intro paragraph
.it

Following is a brief outline of the major features and basic operation of an outline generator application constructed within a Flex lexer specification.
.tl
This outline has been generated using the application described.
.tl

#enable ordering prefixes for outline formatting
.it

Basic operational features
.si
Generates formatted output as indented outlines from plain text source with simple markup
Automatically orders indented outline prefixes
Provides top, bottom, left, right page margins
Prints centered page number on last line of page
Supports shell style comments (^#...$)
Supports Flex debug trace at runtime (-d opt)
.so
Source markup rules, apply to all following lines
.si
Page size and margins (one per line)
.si
 .pl [0-9]+ - Set page length lines
 .pw [0-9]+ - Set page width chars
 .tm [0-9]+ - Set top margin lines
 .bm [0-9]+ - Set bottom margin lines
 .lm [0-9]+ - Set left margin spaces
 .rm [0-9]+ - Set right margin spaces
 .is [0-9]+ - Set indent spaces per level
.so
Control specifiers (one per line)
.si
 .si - Shift in one level
 .so - Shift out one level
 .sl - Shift out to left margin
 .it - Toggle ordering prefixes off/on (def on)
.it
 (Prints lines or paragraphs wrapped to current indentation level when toggled off)
.it
.so
Title lines (Single lines, no wrap)
.si
 .tl[TEXT] - Print text aligned to left margin
 .tc[TEXT] - Print text aligned to page center
 .tl/.tc   - Without trailing text prints empty line
.sl
Examples of use (program name is ol)
.si
./ol infile
./ol -d infile (enable debug trace)
./ol < infile > outfile
./ol -h (Show help and exit)
Posted in Uncategorized
Views 207 Comments 0
« Prev     Main     Next »
Total Comments 0

Comments

 

  



All times are GMT -5. The time now is 05:17 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration