-
Notifications
You must be signed in to change notification settings - Fork 677
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
code-block table should be wrapped in a <div>
tag
#632
Comments
(Original comment by calfzhou on 2013-11-11T03:16:23.401856+00:00) Checked the history of Looking forward to get the You could give the wrapper |
There is issues with width too, i.e. long lines stretch the table a lot and no scroll bars. I see that MediaWiki instead uses |
Not sure why this issue got auto-closed while the PR is still open ... |
Pygments 2.12 changes the element layout slightly, adding a wrapper <div> that was accidentally removed before: pygments/pygments#632. This patch adds a workaround, so the styling is consistent on both 2.11 and 2.12.
Pygments 2.12 changes the element layout slightly, adding a wrapper <div> that was accidentally removed before: pygments/pygments#632. This patch adds a workaround, so the styling is consistent on both 2.11 and 2.12.
Pygments 2.12.0 slightly changed order of HTML elements which made line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix that by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout.
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout.
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
Pygments 2.12.0 slightly changed the order of HTML elements which makes line numbers look weird with current CSS styles. Quoting changelog: > When linenos=table is used, the <table> itself is now wrapped > with a <div class="highlight"> tag instead of placing it > inside the <td class="code"> cell (#632.) With this change, > the output matches the documented behavior. https://pygments.org/docs/changelog/#version-2-12-0 Related issue: pygments/pygments#632 This commit aims to fix this by further restricting CSS selectors that selected everything under .highlight to only select source code related elements - descendants of .code in the new layout. This was also tested on Pygemnts 2.14.0, version currently packaged for Debian Bookworm https://packages.debian.org/bookworm/armel/python3-pygments
(Original issue 925 created by None on 2013-11-11T02:14:41.552192+00:00)
In the document of HtmlFormatter, there is an example output snippt when
linenos
option is set to"table"
. In this example, the<table>
tag is wrapped in a<div>
tag with"highlight"
class.But current implementation doesn't output the wrapper
<div>
. It generates a bare<table>
tag with class"<cssclass>table"
.Without the wrapping
<div>
, it's hard to styling the table. Say, you cannot easily limit the height of table and make a scroll bar when the number of lines is too large.I hope that the wrapper
<div>
could be, at least, generated by some configuration.The text was updated successfully, but these errors were encountered: