Commit Graph

82 Commits (0422e78fb58c30e8b4ca58a01016376ecc1a08c6)

Author SHA1 Message Date
Jonáš Dujava 0422e78fb5
Support additional reference commands (#162)
Mainly extra starred versions of already supported commands.
These are provided by standard packages `hyperref` and `cleveref`.

Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-08-18 18:11:39 +07:00
Jonáš Dujava efe5afdbb5
Remove dead code (#156)
Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-27 22:14:30 +07:00
Jonáš Dujava f23cf647fb
Implement *Copy macros for commands/environments (#154)
This completes the implementation of all command/environment
definition macros which are provided by LaTeX kernel and
described in https://ctan.org/pkg/usrguide.

Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-27 22:14:14 +07:00
Jonáš Dujava 7ee50b2868
Reorder and refactor code (#152)
Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-24 16:33:35 +07:00
Jonáš Dujava 6706f88d5b
Better color reference (#151)
- add `\mathcolor`
- support directly passing color scheme and spec
- (optionally) include following argument

Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-23 09:16:06 +07:00
Jonáš Dujava 81acebb480
Add extra math environments (#150)
Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-23 09:15:06 +07:00
Jonáš Dujava 55ef65a416
Properly support definition commands from xparse (#148)
Additionally, handle command definition without curly braces
around the defined command name.

Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-21 08:52:18 +07:00
Jonáš Dujava d018f2e662
Add delimiter node (#147)
Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-07-20 21:37:17 +07:00
Patrick Förster 107435ada4
Add luacode and asy as verbatim environments (#141)
Adds the following source code environments:
- `asy`
- `asydef`
- `luacode`
- `luacode*`

Fixes #140.
2024-07-18 17:35:26 +07:00
Jonáš Dujava 08d8b885a3
Support more general URIs in hyperlinks (#134) (#135)
Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
2024-06-23 16:03:58 +07:00
Patrick Förster d06c6a24f4
Add support for parsing hyperlinks (#133) 2024-06-22 09:50:56 +07:00
Patrick Förster 6b572f0f70
Fix parsing wrong superscripts like 10^10 (#132) 2024-06-22 09:50:44 +07:00
Patrick Förster cd82eb40d3
Let \declaretheorem accept multiple env names (#121) 2024-04-28 09:25:04 +07:00
Patrick Förster 01973c115c Reformat grammar.js 2024-04-28 09:20:40 +07:00
MithicSpirit 92760205ee
fix: add "math" as math_environment 2024-04-03 16:41:21 +07:00
Patrick Förster eb552c7022
Add missing citation commands (#115)
Adds the following citation commands:
- `\citeA`
- `\citeR`
- `\citeS`
- `\citeyearR`

Fixes #94.
2024-04-01 15:38:05 +07:00
GI 6ccf34aeb1 fix: Allow optional argument for \author 2024-03-21 23:06:30 +07:00
Patrick Förster 0d598bb95f
Merge pull request #102 from gi1242/bibfixes
Add accept path list for \bibliography
2024-02-14 21:07:48 +07:00
Riley Bruins 3bffe98907 fix: typo in shortintertext node definition 2024-02-13 22:25:30 +07:00
GI 927a45c3cd Add accept path list for \bibliography
Also add \bibliographystyle
2024-01-30 16:20:28 +07:00
martinra 2ae2021d7b
Fix parsing hierarchies of sections and paragraphs (#90)
Split section into section and paragraph.

This allows interleaved occurrences of section hierarchies and paragraphs.
2023-06-11 10:01:52 +07:00
lnay 95d41d9ec4 Clone sections of grammar+scanner relating to pycode env, but for sageblock/silent 2023-06-01 00:18:12 +07:00
João de Felipe d3f3dde488 Stop treating \big, \bigg, \Big, \Bigg delimiters as pairable
Delimiters preceded by these commands are treated by TeX as Ord atoms --
meaning they don't require any sort of pairing, and shouldn't be treated
as such.

See #84 and The TeXbook, page 171.
2023-05-11 03:44:13 +07:00
Patrick Förster 91832daef5 Add support for definition commands from xparse
See #82.
2023-04-16 10:48:21 +07:00
Rylee Lyman 4e1c009f58 remove operators from word and add sub- and superscript captures 2022-11-29 22:00:04 +07:00
Patrick Förster 546d46a44e Add missing "\big"-style commands 2022-10-26 10:49:08 +07:00
Patrick Förster d79f08baea
Do not associate brack_group with generic_command (#51)
Do not match bracket groups inside the generic command rule. Instead, only parse brackets for specific commands.

Fixes #48.
2022-10-26 09:49:18 +07:00
Patrick Förster 3e7d2f9508 Extend math_delimiter rule
Allow \big, \bigl and \bigr commands in addition to \left and \right.

See #58.
2022-10-25 22:11:45 +07:00
Patrick Förster 2d5f17ebd1 Allow options when using minted environment
See #55.
2022-10-06 18:57:52 +07:00
Patrick Förster 23463ca6b8 Remove math_set rule
See #44.
2022-05-14 12:48:33 +07:00
Patrick Förster 8ac966ece5 Fix color_definition rule
See #44.
2022-05-14 12:36:31 +07:00
Patrick Förster 3b370b5ca3 Add parens and brackets to math_delimiter rule
See #43.
2022-05-11 20:22:05 +07:00
Patrick Förster 692215e99f Parse \left and \right correctly
See #43.
2022-05-11 18:35:11 +07:00
Patrick Förster 8c5d90e78f Do not match groups with parens after commands
See #42.
2022-04-23 15:10:18 +07:00
Patrick Förster e550c23486 Fix curly_group_impl rule
See #36.
2022-04-14 18:21:52 +07:00
Patrick Förster ab9c1c59de Add rule for math environments 2022-04-13 21:55:48 +07:00
Patrick Förster ba902decb0 Refactor special environment rules 2022-04-13 21:22:35 +07:00
Patrick Förster a4efa1f1a3 Allow bracket groups after \title 2022-04-13 20:38:48 +07:00
Patrick Förster e4112094b3 Add \renewcommand to environment_definition rule
See #40.
2022-04-13 20:31:05 +07:00
Patrick Förster a6926f5263 Parse section with custom ToC entry
See #39.
2022-04-13 20:28:48 +07:00
Patrick Förster fc69ab784a Add rules for \author and \title
See #36.
2022-04-13 20:19:21 +07:00
Patrick Förster d43d8f6c46 Add support for paired delimiters
See #36.
2022-04-11 20:50:05 +07:00
Patrick Förster 5afabaea0e Add starred commands for theorem definitions
See #36
2022-04-11 20:41:35 +07:00
Patrick Förster 5686c9c831 Add text_mode rule for \text command
See #3.
2022-03-16 20:12:58 +07:00
Patrick Förster 1ea9f87d30 Allow commands as children of text nodes
See #29.
2022-02-26 21:40:59 +07:00
Patrick Förster 7a3d14d057 Rename command to generic_command 2022-02-26 21:15:52 +07:00
Patrick Förster 899b7408d8 Allow default arguments in command definitions 2022-02-26 20:57:05 +07:00
Patrick Förster 1666e9780d Allow multiple paths in \usetikzlibrary command
See #28.
2022-02-18 18:11:49 +07:00
duda 0181c557cb Fix named childnodes 2022-02-15 00:41:16 +07:00
duda 5d96a0b16d Fix precedence; add test 2022-02-14 14:35:49 +07:00