tex2id 1.5.0 → 1.6.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d8e2ba33a9d7a967957e6c3ebbf824b42a2875e79445c3ffee8f16b2860a868b
4
- data.tar.gz: f84f1ae53e549228c14fd08fcfcae3227dbb50fdad57f0c5d9ea096ef2c3f949
3
+ metadata.gz: 5476eb432da2d0c6cc135bd2da0b1eb491cca009cedb50cebab2d080a364ab10
4
+ data.tar.gz: 87a8fe6641b5af03bca1a94971c41cda500babee9a275b5585a157b73935f1fd
5
5
  SHA512:
6
- metadata.gz: 0c13010485f43c21bbc85c320db52181e55778c1782531a7bf506190def3328b7e9849391c9cb80e288264e2d38f951756c1dbbc3dd78d0a642b70e0cfb08aeb
7
- data.tar.gz: ea533c2347afc3d53d31e927ff14ab6dfb772b4dde289e969f7bc80a4257d215bb58f815bd8821679d84df42ac11143c13a0483b7fc895e839526a060a9fb5bf
6
+ metadata.gz: c6c3ae76103f434fdbd860bd7feb9bb4eabd11eb197ea5c9d0a180f4255bdede2a2d21f8d8e7bfed499f8e4dd375f2c903ced8d5c3a8bea5a94d69e3dd9880a5
7
+ data.tar.gz: 484d9c8d0fb4670ce06f819da0a966b130b48f31327b5536254d8d423da114f858c1e635bee9b2732af4b19ecaaa51b8f4f9e7362d6607d8ccf9b889b1e5047d
@@ -5,32 +5,13 @@ class Tex2id::Converter
5
5
 
6
6
  def initialize(source, only_fix_md2inao: false)
7
7
  @source = source
8
- @use_math = false
9
8
  @only_fix_md2inao = only_fix_md2inao
10
9
  @state_stack = []
11
10
  @token_stack = []
12
11
  end
13
12
 
14
- def use_math? = @use_math
15
-
16
13
  def convert
17
- pass1 = check_use_math(@source)
18
- if use_math?
19
- convert_math(pass1)
20
- else
21
- pass1
22
- end
23
- end
24
-
25
- def check_use_math(source)
26
- source.sub(/\bUseMath:\s+(true|false)\b/m) {
27
- @use_math = (Regexp.last_match[1] == "true")
28
- ""
29
- }
30
- end
31
-
32
- def convert_math(source)
33
- pass1 = convert_display_math(source)
14
+ pass1 = convert_display_math(@source)
34
15
  pass2 = convert_inline_math(pass1)
35
16
  pass2
36
17
  end
@@ -1,3 +1,3 @@
1
1
  module Tex2id
2
- VERSION = "1.5.0"
2
+ VERSION = "1.6.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tex2id
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kenta Murata
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-08-06 00:00:00.000000000 Z
11
+ date: 2022-08-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler