Skip to content

Commit

Permalink
Reverse priority of classes to allow overruling booktabs by standard
Browse files Browse the repository at this point in the history
  • Loading branch information
jfbu committed Aug 11, 2022
1 parent 9381bb4 commit 3c17ac7
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions sphinx/writers/latex.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,16 +98,16 @@ def __init__(self, node: Element) -> None:
self.align = node.get('align', 'default')
self.classes: List[str] = node.get('classes', [])
self.styles: List[str] = []
if 'booktabs' in self.classes:
self.styles.append('booktabs')
if 'standard' in self.classes:
self.styles.append('standard')
elif 'borderless' in self.classes:
self.styles.append('borderless')
elif 'standard' in self.classes:
self.styles.append('standard')
if 'colorrows' in self.classes:
self.styles.append('colorrows')
elif 'nocolorrows' in self.classes:
elif 'booktabs' in self.classes:
self.styles.append('booktabs')
if 'nocolorrows' in self.classes:
self.styles.append('nocolorrows')
elif 'colorrows' in self.classes:
self.styles.append('colorrows')
self.colcount = 0
self.colspec: str = None
self.colsep: str = None
Expand Down

0 comments on commit 3c17ac7

Please sign in to comment.