mirror of
https://github.com/LCPQ/QUESTDB_website.git
synced 2024-08-24 21:21:52 +02:00
Use PageRange package to interprete the \excludecolumns command in the input file (allow printer range syntax)
This commit is contained in:
parent
87e3329070
commit
28181e6925
@ -2,6 +2,7 @@ from TexSoup import TexSoup,TexCmd
|
||||
from . import formats
|
||||
from .data import dataFileBase,DataType, method, state, exSet
|
||||
from collections import defaultdict
|
||||
from pagerange import PageRange
|
||||
|
||||
class dfbOptions(object):
|
||||
def __init__(self):
|
||||
@ -96,7 +97,7 @@ class dfbOptions(object):
|
||||
for node in dfbexcludeColumnsNodes:
|
||||
excludeColumns=node.expr
|
||||
if type(excludeColumns) is TexCmd:
|
||||
commas_string=excludeColumns.args[0].value
|
||||
ints=[int(x.strip()) for x in commas_string.split(",")]
|
||||
dfb_Opt.excludeColumns.update(ints)
|
||||
range_string=excludeColumns.args[0].value
|
||||
PageRangeParser=PageRange(range_string)
|
||||
dfb_Opt.excludeColumns.update(PageRangeParser.pages)
|
||||
return dfb_Opt
|
@ -3,3 +3,4 @@ numpy>=1.18.3,<1.20
|
||||
GitPython>=3.1.14
|
||||
PyYAML>=5.3.1
|
||||
TexSoup==0.2.1
|
||||
PageRange>=0.4
|
Loading…
Reference in New Issue
Block a user