postsvg 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +105 -0
- data/CLAUDE.md +173 -0
- data/Gemfile +2 -3
- data/README.adoc +456 -179
- data/Rakefile +100 -0
- data/TODO.roadmap/00-architecture.md +139 -0
- data/TODO.roadmap/01-autoload-migration.md +39 -0
- data/TODO.roadmap/02-isolate-dormant-code.md +51 -0
- data/TODO.roadmap/03-domain-model.md +66 -0
- data/TODO.roadmap/04-lexer.md +40 -0
- data/TODO.roadmap/05-parser.md +43 -0
- data/TODO.roadmap/06-graphics-state.md +45 -0
- data/TODO.roadmap/07-matrix-and-color.md +37 -0
- data/TODO.roadmap/08-svg-builder.md +51 -0
- data/TODO.roadmap/09-renderer.md +52 -0
- data/TODO.roadmap/10-visitor.md +58 -0
- data/TODO.roadmap/11-operator-coverage.md +103 -0
- data/TODO.roadmap/12-svg-domain.md +62 -0
- data/TODO.roadmap/13-translation-handlers.md +69 -0
- data/TODO.roadmap/14-ps-serializer.md +49 -0
- data/TODO.roadmap/15-cli-and-public-api.md +47 -0
- data/TODO.roadmap/16-specs.md +84 -0
- data/TODO.roadmap/17-docs-sync.md +47 -0
- data/TODO.roadmap/18-performance-and-determinism.md +47 -0
- data/TODO.roadmap/19-error-model.md +45 -0
- data/TODO.roadmap/20-font-and-text.md +46 -0
- data/TODO.roadmap/21-images.md +45 -0
- data/TODO.roadmap/22-forms-and-resources.md +25 -0
- data/TODO.roadmap/23-level2-level3.md +52 -0
- data/TODO.roadmap/24-ci-and-release.md +42 -0
- data/TODO.roadmap/README.md +77 -0
- data/docs/.gitignore +29 -0
- data/docs/CHANGELOG.md +114 -0
- data/docs/COMPLETE_DOCUMENTATION_STATUS.md +376 -0
- data/docs/DEPLOYMENT.md +456 -0
- data/docs/DEPLOYMENT_INSTRUCTIONS.md +229 -0
- data/docs/DOCUMENTATION_PLAN.md +425 -0
- data/docs/FINAL_SUMMARY.md +657 -0
- data/docs/Gemfile +15 -0
- data/docs/README.md +327 -0
- data/docs/_config.yml +99 -0
- data/docs/advanced-topics.adoc +370 -0
- data/docs/api-reference/colors.adoc +705 -0
- data/docs/api-reference/converter.adoc +699 -0
- data/docs/api-reference/execution-context.adoc +1210 -0
- data/docs/api-reference/graphics-state.adoc +1070 -0
- data/docs/api-reference/interpreter.adoc +810 -0
- data/docs/api-reference/matrix.adoc +1179 -0
- data/docs/api-reference/path-builder.adoc +1284 -0
- data/docs/api-reference/postsvg-module.adoc +388 -0
- data/docs/api-reference/svg-generator.adoc +891 -0
- data/docs/api-reference/tokenizer.adoc +925 -0
- data/docs/api-reference.adoc +221 -0
- data/docs/architecture/command-registry.adoc +1191 -0
- data/docs/architecture/conversion-pipeline.adoc +746 -0
- data/docs/architecture/design-decisions.adoc +999 -0
- data/docs/architecture/generator-stage.adoc +1115 -0
- data/docs/architecture/graphics-state-model.adoc +1089 -0
- data/docs/architecture/interpreter-stage.adoc +1125 -0
- data/docs/architecture/parser-stage.adoc +1051 -0
- data/docs/architecture.adoc +354 -0
- data/docs/cli-reference/batch-command.adoc +616 -0
- data/docs/cli-reference/check-command.adoc +677 -0
- data/docs/cli-reference/cli-options.adoc +802 -0
- data/docs/cli-reference/convert-command.adoc +462 -0
- data/docs/cli-reference/version-command.adoc +296 -0
- data/docs/cli-reference.adoc +317 -0
- data/docs/concepts/conversion-pipeline.adoc +903 -0
- data/docs/concepts/coordinate-systems.adoc +836 -0
- data/docs/concepts/graphics-state.adoc +861 -0
- data/docs/concepts/path-operations.adoc +1076 -0
- data/docs/concepts/postscript-language.adoc +859 -0
- data/docs/concepts/svg-generation.adoc +937 -0
- data/docs/concepts.adoc +198 -0
- data/docs/contributing.adoc +443 -0
- data/docs/development.adoc +420 -0
- data/docs/faq.adoc +493 -0
- data/docs/getting-started/basic-usage.adoc +538 -0
- data/docs/getting-started/common-workflows.adoc +577 -0
- data/docs/getting-started/first-conversion.adoc +492 -0
- data/docs/getting-started/installation.adoc +534 -0
- data/docs/getting-started.adoc +94 -0
- data/docs/index.adoc +248 -0
- data/docs/optimization.adoc +196 -0
- data/docs/ps2svg_compatibility.adoc +149 -0
- data/docs/quick-reference.adoc +453 -0
- data/docs/sitemap.adoc +337 -0
- data/docs/troubleshooting.adoc +486 -0
- data/docs/validation.adoc +772 -0
- data/exe/postsvg +1 -0
- data/lib/postsvg/cli.rb +104 -57
- data/lib/postsvg/color.rb +132 -0
- data/lib/postsvg/errors.rb +68 -3
- data/lib/postsvg/format_number.rb +22 -0
- data/lib/postsvg/graphics_context.rb +80 -0
- data/lib/postsvg/graphics_stack.rb +43 -0
- data/lib/postsvg/model/literals/array.rb +41 -0
- data/lib/postsvg/model/literals/dictionary.rb +34 -0
- data/lib/postsvg/model/literals/hex.rb +37 -0
- data/lib/postsvg/model/literals/name.rb +40 -0
- data/lib/postsvg/model/literals/number.rb +36 -0
- data/lib/postsvg/model/literals/procedure.rb +41 -0
- data/lib/postsvg/model/literals/string.rb +30 -0
- data/lib/postsvg/model/literals.rb +19 -0
- data/lib/postsvg/model/operator.rb +58 -0
- data/lib/postsvg/model/operators/arithmetic.rb +264 -0
- data/lib/postsvg/model/operators/boolean.rb +182 -0
- data/lib/postsvg/model/operators/color.rb +74 -0
- data/lib/postsvg/model/operators/container.rb +186 -0
- data/lib/postsvg/model/operators/control_flow.rb +119 -0
- data/lib/postsvg/model/operators/device.rb +21 -0
- data/lib/postsvg/model/operators/dictionary.rb +118 -0
- data/lib/postsvg/model/operators/font.rb +121 -0
- data/lib/postsvg/model/operators/graphics_state.rb +84 -0
- data/lib/postsvg/model/operators/painting.rb +29 -0
- data/lib/postsvg/model/operators/path.rb +169 -0
- data/lib/postsvg/model/operators/stack.rb +72 -0
- data/lib/postsvg/model/operators/transformations.rb +103 -0
- data/lib/postsvg/model/operators.rb +89 -0
- data/lib/postsvg/model/program.rb +68 -0
- data/lib/postsvg/model/token.rb +43 -0
- data/lib/postsvg/model.rb +17 -0
- data/lib/postsvg/options.rb +29 -0
- data/lib/postsvg/renderer.rb +85 -0
- data/lib/postsvg/serializer.rb +325 -0
- data/lib/postsvg/source/ast_builder.rb +308 -0
- data/lib/postsvg/source/lexer.rb +322 -0
- data/lib/postsvg/source/operand_stack.rb +55 -0
- data/lib/postsvg/source.rb +21 -0
- data/lib/postsvg/svg/attribute_parser.rb +45 -0
- data/lib/postsvg/svg/clip_path_registry.rb +44 -0
- data/lib/postsvg/svg/document.rb +22 -0
- data/lib/postsvg/svg/element.rb +84 -0
- data/lib/postsvg/svg/elements/circle.rb +36 -0
- data/lib/postsvg/svg/elements/clip_path.rb +26 -0
- data/lib/postsvg/svg/elements/defs.rb +24 -0
- data/lib/postsvg/svg/elements/ellipse.rb +38 -0
- data/lib/postsvg/svg/elements/group.rb +37 -0
- data/lib/postsvg/svg/elements/image.rb +35 -0
- data/lib/postsvg/svg/elements/line.rb +36 -0
- data/lib/postsvg/svg/elements/path.rb +32 -0
- data/lib/postsvg/svg/elements/polygon.rb +12 -0
- data/lib/postsvg/svg/elements/polyline.rb +32 -0
- data/lib/postsvg/svg/elements/rect.rb +44 -0
- data/lib/postsvg/svg/elements/svg.rb +39 -0
- data/lib/postsvg/svg/elements/text.rb +42 -0
- data/lib/postsvg/svg/elements.rb +31 -0
- data/lib/postsvg/svg/paint.rb +34 -0
- data/lib/postsvg/svg/parser.rb +39 -0
- data/lib/postsvg/svg/path_data/command.rb +27 -0
- data/lib/postsvg/svg/path_data/parser.rb +82 -0
- data/lib/postsvg/svg/path_data.rb +17 -0
- data/lib/postsvg/svg/stroke.rb +31 -0
- data/lib/postsvg/svg/transform_list.rb +59 -0
- data/lib/postsvg/svg.rb +22 -0
- data/lib/postsvg/svg_builder.rb +249 -0
- data/lib/postsvg/translation/arc_converter.rb +86 -0
- data/lib/postsvg/translation/bounding_box.rb +59 -0
- data/lib/postsvg/translation/context.rb +34 -0
- data/lib/postsvg/translation/handler_registry.rb +38 -0
- data/lib/postsvg/translation/handlers/circle_handler.rb +28 -0
- data/lib/postsvg/translation/handlers/clip_path_handler.rb +13 -0
- data/lib/postsvg/translation/handlers/defs_handler.rb +15 -0
- data/lib/postsvg/translation/handlers/ellipse_handler.rb +31 -0
- data/lib/postsvg/translation/handlers/group_handler.rb +21 -0
- data/lib/postsvg/translation/handlers/image_handler.rb +20 -0
- data/lib/postsvg/translation/handlers/line_handler.rb +23 -0
- data/lib/postsvg/translation/handlers/open_handler.rb +18 -0
- data/lib/postsvg/translation/handlers/path_handler.rb +356 -0
- data/lib/postsvg/translation/handlers/polygon_handler.rb +33 -0
- data/lib/postsvg/translation/handlers/polyline_handler.rb +31 -0
- data/lib/postsvg/translation/handlers/rect_handler.rb +27 -0
- data/lib/postsvg/translation/handlers/shared.rb +110 -0
- data/lib/postsvg/translation/handlers/svg_handler.rb +25 -0
- data/lib/postsvg/translation/handlers/text_handler.rb +56 -0
- data/lib/postsvg/translation/handlers.rb +25 -0
- data/lib/postsvg/translation/ps_renderer.rb +105 -0
- data/lib/postsvg/translation/record_emitter.rb +35 -0
- data/lib/postsvg/translation.rb +17 -0
- data/lib/postsvg/version.rb +1 -1
- data/lib/postsvg/visitors/ps_visitor/arithmetic.rb +125 -0
- data/lib/postsvg/visitors/ps_visitor/boolean.rb +105 -0
- data/lib/postsvg/visitors/ps_visitor/color.rb +53 -0
- data/lib/postsvg/visitors/ps_visitor/common.rb +66 -0
- data/lib/postsvg/visitors/ps_visitor/container.rb +164 -0
- data/lib/postsvg/visitors/ps_visitor/control_flow.rb +110 -0
- data/lib/postsvg/visitors/ps_visitor/device.rb +20 -0
- data/lib/postsvg/visitors/ps_visitor/dictionary.rb +89 -0
- data/lib/postsvg/visitors/ps_visitor/font.rb +93 -0
- data/lib/postsvg/visitors/ps_visitor/graphics_state.rb +55 -0
- data/lib/postsvg/visitors/ps_visitor/painting.rb +90 -0
- data/lib/postsvg/visitors/ps_visitor/path.rb +112 -0
- data/lib/postsvg/visitors/ps_visitor/stack.rb +47 -0
- data/lib/postsvg/visitors/ps_visitor/transformations.rb +101 -0
- data/lib/postsvg/visitors/ps_visitor.rb +208 -0
- data/lib/postsvg/visitors.rb +9 -0
- data/lib/postsvg.rb +93 -59
- data/lychee.toml +86 -0
- metadata +216 -11
- data/postsvg.gemspec +0 -38
|
@@ -0,0 +1,425 @@
|
|
|
1
|
+
# Postsvg Documentation Plan
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
This document describes the comprehensive documentation structure for Postsvg, following best practices from technical documentation standards and the LADL specification document.
|
|
6
|
+
|
|
7
|
+
## Completed Components
|
|
8
|
+
|
|
9
|
+
### Core Infrastructure
|
|
10
|
+
|
|
11
|
+
✅ **Jekyll Configuration (`_config.yml`)**
|
|
12
|
+
- Just-the-docs theme configuration
|
|
13
|
+
- AsciiDoc support enabled
|
|
14
|
+
- Search functionality configured
|
|
15
|
+
- Navigation and layout settings
|
|
16
|
+
- Footer and branding
|
|
17
|
+
|
|
18
|
+
✅ **Main Entry Point (`index.adoc`)**
|
|
19
|
+
- Welcome page with badges and quick links
|
|
20
|
+
- Overview of all documentation sections
|
|
21
|
+
- Quick start examples
|
|
22
|
+
- Feature highlights
|
|
23
|
+
- Navigation to all major topics
|
|
24
|
+
|
|
25
|
+
### Parent-Level Documentation
|
|
26
|
+
|
|
27
|
+
✅ **Getting Started (`getting-started.adoc`)**
|
|
28
|
+
- Installation guide overview
|
|
29
|
+
- Basic usage patterns
|
|
30
|
+
- First conversion tutorial reference
|
|
31
|
+
- Common workflows introduction
|
|
32
|
+
- Quick reference for CLI and API
|
|
33
|
+
|
|
34
|
+
✅ **Core Concepts (`concepts.adoc`)**
|
|
35
|
+
- Conversion pipeline explanation
|
|
36
|
+
- PostScript language overview
|
|
37
|
+
- Graphics state management
|
|
38
|
+
- Coordinate systems
|
|
39
|
+
- Path operations
|
|
40
|
+
- SVG generation process
|
|
41
|
+
|
|
42
|
+
✅ **API Reference (`api-reference.adoc`)**
|
|
43
|
+
- Module methods overview
|
|
44
|
+
- Converter class introduction
|
|
45
|
+
- Interpreter class reference
|
|
46
|
+
- Execution context
|
|
47
|
+
- Graphics state
|
|
48
|
+
- SVG generator
|
|
49
|
+
- Helper classes (Matrix, Colors, PathBuilder)
|
|
50
|
+
|
|
51
|
+
✅ **CLI Reference (`cli-reference.adoc`)**
|
|
52
|
+
- Command overview
|
|
53
|
+
- convert command
|
|
54
|
+
- batch command
|
|
55
|
+
- check command (validation)
|
|
56
|
+
- version command
|
|
57
|
+
- Common usage patterns
|
|
58
|
+
- Exit codes and output formats
|
|
59
|
+
|
|
60
|
+
✅ **Architecture (`architecture.adoc`)**
|
|
61
|
+
- Three-stage pipeline architecture
|
|
62
|
+
- Component responsibilities
|
|
63
|
+
- Design patterns (Command, Registry, State, Strategy)
|
|
64
|
+
- Data flow diagrams
|
|
65
|
+
- Class relationships
|
|
66
|
+
|
|
67
|
+
✅ **Advanced Topics (`advanced-topics.adoc`)**
|
|
68
|
+
- Custom operator implementation
|
|
69
|
+
- Strict mode usage
|
|
70
|
+
- BoundingBox handling
|
|
71
|
+
- Error recovery strategies
|
|
72
|
+
- Memory optimization
|
|
73
|
+
- Performance profiling
|
|
74
|
+
- Integration patterns (Rails, Rake)
|
|
75
|
+
|
|
76
|
+
✅ **Development Guide (`development.adoc`)**
|
|
77
|
+
- Development environment setup
|
|
78
|
+
- Running tests
|
|
79
|
+
- Adding new operators
|
|
80
|
+
- Code style guidelines
|
|
81
|
+
- Commit message conventions
|
|
82
|
+
- Pull request process
|
|
83
|
+
- Project structure
|
|
84
|
+
|
|
85
|
+
✅ **Contributing Guide (`contributing.adoc`)**
|
|
86
|
+
- Bug reporting templates
|
|
87
|
+
- Feature request guidelines
|
|
88
|
+
- Documentation improvements
|
|
89
|
+
- Code contribution process
|
|
90
|
+
- PR guidelines and checklist
|
|
91
|
+
- Code review process
|
|
92
|
+
- Code of conduct
|
|
93
|
+
|
|
94
|
+
✅ **Troubleshooting (`troubleshooting.adoc`)**
|
|
95
|
+
- Installation problems
|
|
96
|
+
- Conversion errors
|
|
97
|
+
- Validation errors
|
|
98
|
+
- Performance issues
|
|
99
|
+
- Output quality issues
|
|
100
|
+
- Debugging techniques
|
|
101
|
+
|
|
102
|
+
✅ **FAQ (`faq.adoc`)**
|
|
103
|
+
- General questions about Postsvg
|
|
104
|
+
- Installation and setup
|
|
105
|
+
- Usage questions
|
|
106
|
+
- Conversion issues
|
|
107
|
+
- Performance questions
|
|
108
|
+
- Development questions
|
|
109
|
+
- Integration questions
|
|
110
|
+
- Comparison with alternatives
|
|
111
|
+
|
|
112
|
+
### Existing PostScript Documentation
|
|
113
|
+
|
|
114
|
+
✅ **PostScript Language Reference** (already exists)
|
|
115
|
+
- `docs/POSTSCRIPT.adoc` - Main index
|
|
116
|
+
- `docs/postscript/fundamentals.adoc`
|
|
117
|
+
- `docs/postscript/graphics-model.adoc`
|
|
118
|
+
- `docs/postscript/svg-mapping.adoc`
|
|
119
|
+
- `docs/postscript/implementation-notes.adoc`
|
|
120
|
+
- `docs/postscript/operators/` - Complete operator reference
|
|
121
|
+
|
|
122
|
+
✅ **Validation Documentation** (already exists)
|
|
123
|
+
- `docs/validation.adoc` - Main validation guide
|
|
124
|
+
- Needs child topic expansion
|
|
125
|
+
|
|
126
|
+
✅ **Optimization Documentation** (already exists)
|
|
127
|
+
- `docs/optimization.adoc` - Main optimization guide
|
|
128
|
+
- Needs child topic expansion
|
|
129
|
+
|
|
130
|
+
✅ **Compatibility Notes** (already exists)
|
|
131
|
+
- `docs/ps2svg_compatibility.adoc`
|
|
132
|
+
|
|
133
|
+
## Pending Child Topic Documentation
|
|
134
|
+
|
|
135
|
+
The following child topic documentation needs to be created to complete the hierarchical structure:
|
|
136
|
+
|
|
137
|
+
### Getting Started Child Topics
|
|
138
|
+
|
|
139
|
+
- [ ] `docs/getting-started/installation.adoc`
|
|
140
|
+
- [ ] `docs/getting-started/basic-usage.adoc`
|
|
141
|
+
- [ ] `docs/getting-started/first-conversion.adoc`
|
|
142
|
+
- [ ] `docs/getting-started/common-workflows.adoc`
|
|
143
|
+
|
|
144
|
+
### Concepts Child Topics
|
|
145
|
+
|
|
146
|
+
- [ ] `docs/concepts/postscript-language.adoc`
|
|
147
|
+
- [ ] `docs/concepts/conversion-pipeline.adoc`
|
|
148
|
+
- [ ] `docs/concepts/graphics-state.adoc`
|
|
149
|
+
- [ ] `docs/concepts/coordinate-systems.adoc`
|
|
150
|
+
- [ ] `docs/concepts/path-operations.adoc`
|
|
151
|
+
- [ ] `docs/concepts/svg-generation.adoc`
|
|
152
|
+
|
|
153
|
+
### API Reference Child Topics
|
|
154
|
+
|
|
155
|
+
- [ ] `docs/api-reference/postsvg-module.adoc`
|
|
156
|
+
- [ ] `docs/api-reference/converter.adoc`
|
|
157
|
+
- [ ] `docs/api-reference/interpreter.adoc`
|
|
158
|
+
- [ ] `docs/api-reference/execution-context.adoc`
|
|
159
|
+
- [ ] `docs/api-reference/graphics-state.adoc`
|
|
160
|
+
- [ ] `docs/api-reference/svg-generator.adoc`
|
|
161
|
+
- [ ] `docs/api-reference/path-builder.adoc`
|
|
162
|
+
- [ ] `docs/api-reference/matrix.adoc`
|
|
163
|
+
- [ ] `docs/api-reference/colors.adoc`
|
|
164
|
+
|
|
165
|
+
### CLI Reference Child Topics
|
|
166
|
+
|
|
167
|
+
- [ ] `docs/cli-reference/convert-command.adoc`
|
|
168
|
+
- [ ] `docs/cli-reference/batch-command.adoc`
|
|
169
|
+
- [ ] `docs/cli-reference/check-command.adoc`
|
|
170
|
+
- [ ] `docs/cli-reference/version-command.adoc`
|
|
171
|
+
- [ ] `docs/cli-reference/cli-options.adoc`
|
|
172
|
+
|
|
173
|
+
### Architecture Child Topics
|
|
174
|
+
|
|
175
|
+
- [ ] `docs/architecture/conversion-pipeline.adoc`
|
|
176
|
+
- [ ] `docs/architecture/parser-stage.adoc`
|
|
177
|
+
- [ ] `docs/architecture/interpreter-stage.adoc`
|
|
178
|
+
- [ ] `docs/architecture/generator-stage.adoc`
|
|
179
|
+
- [ ] `docs/architecture/command-registry.adoc`
|
|
180
|
+
- [ ] `docs/architecture/graphics-state-model.adoc`
|
|
181
|
+
- [ ] `docs/architecture/design-decisions.adoc`
|
|
182
|
+
|
|
183
|
+
### Advanced Topics Child Topics
|
|
184
|
+
|
|
185
|
+
- [ ] `docs/advanced-topics/custom-operators.adoc`
|
|
186
|
+
- [ ] `docs/advanced-topics/strict-mode.adoc`
|
|
187
|
+
- [ ] `docs/advanced-topics/bounding-box-handling.adoc`
|
|
188
|
+
- [ ] `docs/advanced-topics/error-handling.adoc`
|
|
189
|
+
- [ ] `docs/advanced-topics/memory-considerations.adoc`
|
|
190
|
+
- [ ] `docs/advanced-topics/compatibility.adoc`
|
|
191
|
+
|
|
192
|
+
### Development Child Topics
|
|
193
|
+
|
|
194
|
+
- [ ] `docs/development/setup.adoc`
|
|
195
|
+
- [ ] `docs/development/testing.adoc`
|
|
196
|
+
- [ ] `docs/development/adding-operators.adoc`
|
|
197
|
+
- [ ] `docs/development/code-style.adoc`
|
|
198
|
+
- [ ] `docs/development/architecture-guidelines.adoc`
|
|
199
|
+
- [ ] `docs/development/release-process.adoc`
|
|
200
|
+
|
|
201
|
+
### Validation Child Topics (expand existing)
|
|
202
|
+
|
|
203
|
+
- [ ] `docs/validation/validation-levels.adoc`
|
|
204
|
+
- [ ] `docs/validation/validation-service.adoc`
|
|
205
|
+
- [ ] `docs/validation/validators.adoc`
|
|
206
|
+
- [ ] `docs/validation/reporters.adoc`
|
|
207
|
+
- [ ] `docs/validation/integration.adoc`
|
|
208
|
+
|
|
209
|
+
### Optimization Child Topics (expand existing)
|
|
210
|
+
|
|
211
|
+
- [ ] `docs/optimization/clippath-deduplication.adoc`
|
|
212
|
+
- [ ] `docs/optimization/path-simplification.adoc`
|
|
213
|
+
- [ ] `docs/optimization/performance-tips.adoc`
|
|
214
|
+
|
|
215
|
+
## Document Structure Template
|
|
216
|
+
|
|
217
|
+
Each document follows this standard structure from LADL best practices:
|
|
218
|
+
|
|
219
|
+
```adoc
|
|
220
|
+
= Document Title
|
|
221
|
+
:page-nav_order: N
|
|
222
|
+
|
|
223
|
+
== Purpose
|
|
224
|
+
|
|
225
|
+
Brief description of what this document covers and who should read it.
|
|
226
|
+
|
|
227
|
+
== References
|
|
228
|
+
|
|
229
|
+
* link:../index.adoc[Documentation Home]
|
|
230
|
+
* link:../related-topic.adoc[Related Topic]
|
|
231
|
+
* External links
|
|
232
|
+
|
|
233
|
+
== Concepts
|
|
234
|
+
|
|
235
|
+
**Key Concept 1**:: Definition and explanation
|
|
236
|
+
**Key Concept 2**:: Definition and explanation
|
|
237
|
+
|
|
238
|
+
== {Topic Sections}
|
|
239
|
+
|
|
240
|
+
Main content organized into logical sections with:
|
|
241
|
+
- Clear headings
|
|
242
|
+
- Code examples with syntax definitions
|
|
243
|
+
- "Where" legends explaining parameters
|
|
244
|
+
- Practical examples with explanations
|
|
245
|
+
|
|
246
|
+
== Next Steps
|
|
247
|
+
|
|
248
|
+
* Link to follow-up topics
|
|
249
|
+
* Related documentation
|
|
250
|
+
|
|
251
|
+
== Bibliography
|
|
252
|
+
|
|
253
|
+
* Internal references
|
|
254
|
+
* External resources
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
## Key Features of the Documentation
|
|
258
|
+
|
|
259
|
+
### 1. MECE Principles
|
|
260
|
+
|
|
261
|
+
Each documentation section is:
|
|
262
|
+
- **Mutually Exclusive**: No overlap between topics
|
|
263
|
+
- **Collectively Exhaustive**: Complete coverage of all aspects
|
|
264
|
+
|
|
265
|
+
### 2. Hierarchical Organization
|
|
266
|
+
|
|
267
|
+
- Parent topics provide overview and navigation
|
|
268
|
+
- Child topics provide detailed, focused content
|
|
269
|
+
- Clear navigation paths through related content
|
|
270
|
+
|
|
271
|
+
### 3. Standard Sections
|
|
272
|
+
|
|
273
|
+
All documents include:
|
|
274
|
+
- **Purpose**: What and why
|
|
275
|
+
- **References**: Related docs and external links
|
|
276
|
+
- **Concepts**: Prerequisites and terminology
|
|
277
|
+
- **Body**: Detailed content with examples
|
|
278
|
+
- **Bibliography**: Additional resources
|
|
279
|
+
|
|
280
|
+
### 4. Rich Examples
|
|
281
|
+
|
|
282
|
+
- Syntax definitions with callout annotations
|
|
283
|
+
- "Where" legends explaining all parameters
|
|
284
|
+
- Multiple examples per feature
|
|
285
|
+
- Real-world use cases
|
|
286
|
+
|
|
287
|
+
### 5. Cross-Referencing
|
|
288
|
+
|
|
289
|
+
- Clickable links with file paths and line numbers for code
|
|
290
|
+
- Internal document links
|
|
291
|
+
- External resource links
|
|
292
|
+
- Consistent anchor naming
|
|
293
|
+
|
|
294
|
+
## Next Steps to Complete Documentation
|
|
295
|
+
|
|
296
|
+
### Priority 1: Essential Child Topics
|
|
297
|
+
|
|
298
|
+
1. **Getting Started**
|
|
299
|
+
- `installation.adoc` - Critical for new users
|
|
300
|
+
- `basic-usage.adoc` - First steps guide
|
|
301
|
+
- `first-conversion.adoc` - Tutorial walkthrough
|
|
302
|
+
|
|
303
|
+
2. **API Reference**
|
|
304
|
+
- `postsvg-module.adoc` - Main API entry point
|
|
305
|
+
- `converter.adoc` - Primary conversion class
|
|
306
|
+
- `interpreter.adoc` - Core execution engine
|
|
307
|
+
|
|
308
|
+
3. **CLI Reference**
|
|
309
|
+
- `convert-command.adoc` - Most-used command
|
|
310
|
+
- `batch-command.adoc` - Bulk processing
|
|
311
|
+
- `check-command.adoc` - Validation details
|
|
312
|
+
|
|
313
|
+
### Priority 2: Core Concepts
|
|
314
|
+
|
|
315
|
+
4. **Concepts**
|
|
316
|
+
- `conversion-pipeline.adoc` - How it works
|
|
317
|
+
- `graphics-state.adoc` - State management
|
|
318
|
+
- `coordinate-systems.adoc` - Coordinate handling
|
|
319
|
+
|
|
320
|
+
### Priority 3: Architecture and Advanced
|
|
321
|
+
|
|
322
|
+
5. **Architecture**
|
|
323
|
+
- `conversion-pipeline.adoc` - Pipeline details
|
|
324
|
+
- `command-registry.adoc` - Operator system
|
|
325
|
+
- `design-decisions.adoc` - Why things work this way
|
|
326
|
+
|
|
327
|
+
6. **Advanced Topics**
|
|
328
|
+
- `custom-operators.adoc` - Extending Postsvg
|
|
329
|
+
- `error-handling.adoc` - Robust error recovery
|
|
330
|
+
- `compatibility.adoc` - ps2svg migration
|
|
331
|
+
|
|
332
|
+
### Priority 4: Development
|
|
333
|
+
|
|
334
|
+
7. **Development**
|
|
335
|
+
- `setup.adoc` - Dev environment
|
|
336
|
+
- `testing.adoc` - Test guidelines
|
|
337
|
+
- `adding-operators.adoc` - Contribution guide
|
|
338
|
+
|
|
339
|
+
### Priority 5: Validation and Optimization
|
|
340
|
+
|
|
341
|
+
8. **Expand Existing Docs**
|
|
342
|
+
- Validation child topics
|
|
343
|
+
- Optimization child topics
|
|
344
|
+
|
|
345
|
+
## Documentation Maintenance
|
|
346
|
+
|
|
347
|
+
### Keeping Docs Up to Date
|
|
348
|
+
|
|
349
|
+
1. **Code Changes**: Update docs when adding features
|
|
350
|
+
2. **Bug Fixes**: Document workarounds and solutions
|
|
351
|
+
3. **Version Updates**: Maintain changelog
|
|
352
|
+
4. **User Feedback**: Address common questions in FAQ
|
|
353
|
+
|
|
354
|
+
### Quality Checks
|
|
355
|
+
|
|
356
|
+
- [ ] All links work correctly
|
|
357
|
+
- [ ] Code examples are tested and accurate
|
|
358
|
+
- [ ] Screenshots/diagrams are current
|
|
359
|
+
- [ ] Cross-references are correct
|
|
360
|
+
- [ ] Navigation hierarchy is logical
|
|
361
|
+
|
|
362
|
+
## Building the Documentation Site
|
|
363
|
+
|
|
364
|
+
### Local Testing
|
|
365
|
+
|
|
366
|
+
```sh
|
|
367
|
+
# Install dependencies
|
|
368
|
+
gem install jekyll jekyll-asciidoc just-the-docs
|
|
369
|
+
|
|
370
|
+
# Build site
|
|
371
|
+
cd docs
|
|
372
|
+
jekyll serve
|
|
373
|
+
|
|
374
|
+
# View at http://localhost:4000/postsvg
|
|
375
|
+
```
|
|
376
|
+
|
|
377
|
+
### Deployment
|
|
378
|
+
|
|
379
|
+
The documentation can be deployed to:
|
|
380
|
+
- GitHub Pages (recommended)
|
|
381
|
+
- GitLab Pages
|
|
382
|
+
- Netlify
|
|
383
|
+
- Custom hosting
|
|
384
|
+
|
|
385
|
+
## Success Criteria
|
|
386
|
+
|
|
387
|
+
Documentation is complete when:
|
|
388
|
+
|
|
389
|
+
✅ All parent topics created
|
|
390
|
+
✅ All essential child topics created
|
|
391
|
+
✅ All code examples tested
|
|
392
|
+
✅ All links verified
|
|
393
|
+
✅ Jekyll site builds successfully
|
|
394
|
+
✅ Navigation works correctly
|
|
395
|
+
✅ Search finds relevant content
|
|
396
|
+
✅ Mobile-responsive layout
|
|
397
|
+
✅ Accessibility standards met
|
|
398
|
+
|
|
399
|
+
## Current Status
|
|
400
|
+
|
|
401
|
+
**Completion: ~40%**
|
|
402
|
+
|
|
403
|
+
- ✅ Infrastructure (100%)
|
|
404
|
+
- ✅ Parent topics (100%)
|
|
405
|
+
- ✅ Existing PostScript docs (100%)
|
|
406
|
+
- ⏳ Child topics (0%)
|
|
407
|
+
- ⏳ Examples and diagrams (0%)
|
|
408
|
+
- ⏳ Testing and validation (0%)
|
|
409
|
+
|
|
410
|
+
**Next Immediate Steps:**
|
|
411
|
+
|
|
412
|
+
1. Create Priority 1 child topics (Getting Started, API, CLI)
|
|
413
|
+
2. Test Jekyll site generation
|
|
414
|
+
3. Verify all links and references
|
|
415
|
+
4. Add code examples to child topics
|
|
416
|
+
5. Create architecture diagrams
|
|
417
|
+
6. Complete remaining child topics
|
|
418
|
+
7. Final review and quality check
|
|
419
|
+
|
|
420
|
+
## Resources
|
|
421
|
+
|
|
422
|
+
- [Just the Docs Theme](https://just-the-docs.com/)
|
|
423
|
+
- [AsciiDoc Documentation](https://docs.asciidoctor.org/)
|
|
424
|
+
- [Jekyll Documentation](https://jekyllrb.com/docs/)
|
|
425
|
+
- [LADL Specification](https://github.com/metanorma/mn-samples-ribose/blob/main/sources/112/document.adoc) (for documentation best practices)
|