Christian Muehlhaeuser
|
82d6db7c7d
|
Add new element style 'enumeration', used for items in ordered lists
|
2019-12-05 10:05:15 +01:00 |
|
Christian Muehlhaeuser
|
1e195cc3de
|
Don't render List's prefix in ListElement, as it later gets replaced by a ParagraphElement
|
2019-12-05 09:50:17 +01:00 |
|
Christian Muehlhaeuser
|
60e71effec
|
HeadingElement now supports indent & margin
|
2019-12-05 09:44:20 +01:00 |
|
Christian Muehlhaeuser
|
4c98804213
|
Move BlockStack into a separate file blockstack.go
|
2019-12-05 08:06:08 +01:00 |
|
Christian Muehlhaeuser
|
5096c6696e
|
Write Element's Entering-output to the correct buffer
|
2019-12-04 13:54:17 +01:00 |
|
Christian Muehlhaeuser
|
512abfe4c0
|
Create BlockElement even if there's no style for it
|
2019-12-04 13:42:40 +01:00 |
|
Christian Muehlhaeuser
|
15d9fd129b
|
Handle Lists as a block element, which supports margins & indents
|
2019-12-04 13:37:14 +01:00 |
|
Christian Muehlhaeuser
|
038f2dd684
|
Handle write buffers & cascading styles in BlockStack
|
2019-12-04 13:36:31 +01:00 |
|
Christian Muehlhaeuser
|
9134cddd48
|
Fix filename baseelement.go
|
2019-12-04 09:51:59 +01:00 |
|
Christian Muehlhaeuser
|
ed7def899e
|
Only remove paragraph indent/margin for list items
|
2019-12-04 09:51:31 +01:00 |
|
Christian Muehlhaeuser
|
550c0bdbd5
|
Don't indent line if all we're outputting is ANSI sequences
|
2019-12-04 08:56:15 +01:00 |
|
Christian Muehlhaeuser
|
f7244397d2
|
Support margins in block elements
|
2019-12-04 06:59:53 +01:00 |
|
Christian Muehlhaeuser
|
419fda75c9
|
Support margin style flag
|
2019-12-04 06:58:28 +01:00 |
|
Christian Muehlhaeuser
|
8bcc61ace1
|
Use IndentFunc to style indents correctly
|
2019-12-04 06:38:55 +01:00 |
|
Christian Muehlhaeuser
|
ca06d9968c
|
Add StyleStack.Parent, returning the current style's parent
|
2019-12-04 06:38:10 +01:00 |
|
Christian Muehlhaeuser
|
9974d6bad9
|
Support handling indents with an IndentFunc
|
2019-12-04 06:37:37 +01:00 |
|
Christian Muehlhaeuser
|
b518696b44
|
Use renderText even without an active style
|
2019-12-04 05:47:57 +01:00 |
|
Christian Muehlhaeuser
|
afd83210ea
|
Simplify code
|
2019-12-04 05:38:54 +01:00 |
|
Christian Muehlhaeuser
|
92e1c2dde8
|
Use PaddingWriter to render paragraphs
|
2019-12-04 05:21:37 +01:00 |
|
Christian Muehlhaeuser
|
c2a1ec4ccd
|
Use IndentWriter proxied by AnsiWriter
|
2019-12-04 05:20:30 +01:00 |
|
Christian Muehlhaeuser
|
7908b07c31
|
Reset and restore ANSI state before writing indent
|
2019-12-04 05:19:04 +01:00 |
|
Christian Muehlhaeuser
|
38b088ef2d
|
Add PaddingWriter, an io.Writer proxy, that keeps lines at (least at) equal width
|
2019-12-04 05:17:54 +01:00 |
|
Christian Muehlhaeuser
|
ad9bc4cb46
|
Add AnsiWriter, a stateful io.Writer proxy that tracks the latest ANSI color sequence
|
2019-12-04 05:17:05 +01:00 |
|
Christian Muehlhaeuser
|
7184df4a14
|
Add StyleStack.Indent and .With
|
2019-12-04 04:54:57 +01:00 |
|
Christian Muehlhaeuser
|
324339551c
|
Remove indent for list-item paragraphs
|
2019-12-02 16:01:43 +01:00 |
|
Christian Muehlhaeuser
|
340f345efe
|
Fixed rune handling in IndentWriter
|
2019-12-02 15:39:12 +01:00 |
|
Christian Muehlhaeuser
|
8ecdd0e83c
|
Add error handling to IndentWriter
|
2019-12-02 15:24:07 +01:00 |
|
Christian Muehlhaeuser
|
d0b616b12b
|
Children in a Document or Paragraph element inherit their parent's color styles
|
2019-12-02 15:23:45 +01:00 |
|
Christian Muehlhaeuser
|
bbd7dfecce
|
Initialize paragraph buffer in ParagraphElement
|
2019-12-02 15:22:30 +01:00 |
|
Christian Muehlhaeuser
|
011c602e64
|
Render prefix/suffix in current style
|
2019-12-02 15:20:55 +01:00 |
|
Christian Muehlhaeuser
|
e43288b69c
|
Check for style being nil in renderText helper
|
2019-12-02 15:20:11 +01:00 |
|
Christian Muehlhaeuser
|
f27536eeb4
|
Add cascading style helpers
|
2019-12-02 15:19:25 +01:00 |
|
Christian Muehlhaeuser
|
d6d52829bb
|
Make document indentable
|
2019-11-30 08:07:40 +01:00 |
|
Christian Muehlhaeuser
|
fca5fd91d6
|
Fix background colors not being applied correctly
|
2019-11-30 07:04:48 +01:00 |
|
Christian Muehlhaeuser
|
87aaa94b41
|
Fix IndentWriter indenting after trailing line-breaks
|
2019-11-30 06:52:07 +01:00 |
|
Christian Muehlhaeuser
|
72e53c38d2
|
Add IdentWriter
|
2019-11-30 06:45:33 +01:00 |
|
Christian Muehlhaeuser
|
d37d023d5d
|
Support styled indents for block elements
|
2019-11-30 06:43:13 +01:00 |
|
Christian Muehlhaeuser
|
f70d879a63
|
Bump reflow dependency
|
2019-11-28 06:12:36 +01:00 |
|
Christian Muehlhaeuser
|
e768cd63bf
|
Use io.Writer directly instead of using Fprintf to print strings
|
2019-11-28 05:48:31 +01:00 |
|
Christian Muehlhaeuser
|
f1a62c8b72
|
Redundant code cleanup
|
2019-11-28 02:32:11 +01:00 |
|
Christian Muehlhaeuser
|
d4d0a3e313
|
Let users define their own element prefix/suffix in styles
|
2019-11-28 02:28:54 +01:00 |
|
Christian Muehlhaeuser
|
8ddf4be8b2
|
Add image_text style, which lets you change the look of an image's name/alt
|
2019-11-28 02:27:00 +01:00 |
|
Christian Muehlhaeuser
|
59b8ecde6d
|
Render each paragraph individually and reflow text only inside paragraphs
|
2019-11-28 02:23:29 +01:00 |
|
Christian Muehlhaeuser
|
a601b62b90
|
Move listitem styling to style JSON
|
2019-11-26 22:42:52 +01:00 |
|
Christian Muehlhaeuser
|
730f9bd2fb
|
Let users define a prefix & suffix for style elements
|
2019-11-26 22:39:39 +01:00 |
|
Christian Muehlhaeuser
|
425d236a44
|
Embed default dark style into binary
|
2019-11-26 21:05:37 +01:00 |
|
Christian Muehlhaeuser
|
8f086bc134
|
Drop redundant TableData struct
|
2019-11-26 04:37:30 +01:00 |
|
Christian Muehlhaeuser
|
8fd35dc929
|
Simplify & cleanup RenderNode
|
2019-11-26 04:28:35 +01:00 |
|
Christian Muehlhaeuser
|
9eee4b13c3
|
Table rendering (#40)
Renders markdown tables.
|
2019-11-26 04:21:22 +01:00 |
|
Christian Muehlhaeuser
|
f47f525238
|
Handle renderer errors
|
2019-11-26 03:58:33 +01:00 |
|