New answers tagged

2

Language auto-detection for assembly language seems to be broken. For example, note the lack of highlighting in the question on Printing an integer as a string with AT&T syntax, with Linux system calls instead of printf. After editing my answer to use ```lang-assembly on the main code block, that block has highlighting but the others don't. (And does ...


9

What to do if highlight.js supports a language but Stack Exchange doesn't? There's an entire Mathematica StackExchange, and so Mathematica syntax highlight is clearly very important to us. But when I did some digging to find the highlight.js bundle that SE seems to be serving, Mathematica isn't in the registerLanguage("...", ...) blocks, even ...


2

I see in the next line after the red circle that style="width: 0%". I believe this may be the cause of the problem. For example, according to CSS width property, the "%" option "Defines the width in percent of the containing block". Also, with Tryit Editor v3.6, changing any of the width values to 0% and then pressing the green &...


5

Does highlight.js support emphasis in blocks formatted as "code" (ie indented 4 spaces)? Paraphrasing an MSE question: In-code highlighting (anything will do), would be a great way to emphasise the important parts. Currently, the best people can do is ASCII art arrows, eg: printf("%5s", "foo") ^--- add a width value ...


0

This has been fixed on my phone now. Since it's not an issue any longer, I'm going to accept this answer.


2

feature-request Firstly, the difference between 1.3 and 1.6 for the new line-height changes is actually 1.45, not 1.5. Second, I would like to have the line-heights added as options in preferences, which would be a real accessibility improvement.


9

I've just tried the following piece of JavaScript code (from this answer of mine in Code Golf) because Google Prettify was not parsing the regular expression followed by an inline comment correctly. That's why I used alternate slash characters in the original post (I've turned them back into regular slash characters below). But this is much worse now, as the ...


24

bug status-review <!-- language-all: lang-none --> hint doesn't seem to work anymore This post has a <!-- language-all: lang-none --> hint at the top of the post to prevent all the code blocks in it from being highlighted. I tried changing lang-none to none and it still didn't work. (As you say in your post, Prettify identifiers will still ...


8

Will the <!-- language: [language] --> hint be disappearing? Back when SE was switching to CommonMark, we were told that the old <!-- language: [language] --> syntax had been deprecated and was subject to removal in the future. (Prior to the implementation of code fences, this was the proper syntax to force a single block of code to be ...


7

I also agree with this, one hundred percent. It is only too true that we all require slightly different settings to feel comfortable. But: Extensions, userscripts, and various other "Band-aids" are all very well, but making lots of us use multiple third-party resources to revert the various poor design choices made by Stack Exchange is...not ...


2

I clicked the link and nothing was destroyed. My browser did not crash. The sandbox contains things that can break design, that's one of its original goals - to find such things, and report them. If you're concerned about bad formatting and don't want to see it, don't view the sandbox. If you reached the sandbox by mistake and want to get out of it, click ...


9

We have been waiting for Verilog and SystemVerilog (SV) highlighting for a long time. Apparently we will have Verilog support with highlight.js, but SV will continue to be unsupported. Still much better than before. I'm happy with the change and appreciate your effort. Let me put some Verilog code (from highlight.js demo) here to see the result after the ...


17

😄 Thanks for doing this! I'm happy about this outcome, as I was a major proponent of switching to highlight.js back in 2016. Great! …but what changed? To satisfy my own curiosity, I'm wondering if you have an explanation or theory for what changed between 2016 and now to make the switch feasible. Oded's performance analysis seemed to raise some major issues,...


5

Given that the design system documentation explicitly mentions small text, is there a chance of finally getting the <small> tag as allowed HTML in Markdown posts? The case for <small> has been made many times and, most saliently, people liberally abuse <sup>/<sub>/both as a workaround, so all the arguments against introducing the tag ...


9

There has been times that I've turned off code highlighting with <!-- language: lang-none --> because Prettify was getting it wrong, and no highlighting is better than wrong highlighting. (The example that comes to mind was a Bash snippet where # wasn't a comment indicator, but Prettify thought it was.) After this change goes through, should I go back ...


46

I'd like to say that I appreciate this post. It is clear, very informative, very detailled, and to me shows that person's concern for the community. Of course, there will always be different opinion on the result ("I prefer the former highlighting" "I prefer the new one!") but that is inevitable. I find the reasons to change (and the ...


71

I found it rather frustrating that I couldn't easily see how the before/after pictures differed, so I did a bit of cutting and pasting so I could look at the before/after side by side to compare them more easily. Then it occurred to me that others might like to do the same, so feel free to have a look. Should be the same basic info as in the question, but ...


127

Can Stack Exchange please update to newer versions of Highlight.js on a regular cycle, rather than only on request? As I said in my prior post reporting Google's discontinuation of Prettify, the process of filing bugs and feature requests with syntax highlighting would be quite drawn out and take a needlessly long time. The process was like this: File a bug ...


3

I have the same problem since months and I wanted to do a report myself but never found the time to. The possible duplicate suggestions blend with each other when scrolling through them. If you do not scroll they don't blend. To be more precise, the suggestion which is on top persists while the following question scrolls up. The result is that both more or ...


2

I am also facing the same issue ever time while posting a question. Firefox: 80.0.1 (64 Bit) OS: Windows 7 64 Bit And the observation is, before scrolling into "Similar Questions", if scroll the entire page a little bit and then performs scroll in "Similar Questions" section does not create any issue of overlapped styling.


4

Links around code don't show up on the mobile site See the screenshot of an answer of mine (as it appears on both Firefox and Chrome on Android): Note that I refer to "documentation I have linked" yet don't appear to have linked anything. In reality I've actually inserted a link around the function name as follows ... use [`PyArray_ZEROS`](http://...


2

Based on what I suggested in the comments and what was amended by Tim Stone I've gone ahead and created this pull request. This adds CSS rules to handle the text overflow and introduces a title attribute on the <dt> element. I consider this for now a quick-fix while we come up with a better suited solution that also works for touch devices (title only ...


7

bug Single-line lists (without <p>) have a large amount of spacing: Hello World Test Markdown: - Hello - World - Test This looks exactly the same as lists with paragraphs: Hello World Test Markdown: - Hello - Hello - World Lists without blank lines between the items shouldn't get rendered as a paragraph (and they don't, no <p> tag), and ...


17

I want to draw readers' attention, particularly that of @AaronShekey, to the fact that the W3C does not actually recommend setting the line height to 1.5 or higher. The relevant recommendations seem to be WCAG criteria 1.4.12 (Text Spacing) and 1.4.8 (Visual Presentation). Criterion 1.4.12 regarding text spacing reads: In content implemented using markup ...


16

I want to draw readers' attention the fact that the W3C does not actually recommend setting the line height to 1.5 or higher. The relevant recommendations seem to be WCAG criteria 1.4.12 (Text Spacing) and 1.4.8 (Visual Presentation). Criterion 1.4.12 regarding text spacing reads (emphasis mine): In content implemented using markup languages that support ...


5

The best solution would be to add some global color settings to the users profile that would be valid throughout all sites. The main goal should be readability for the person reading the text, not that it looks pretty to the web designer. Only the user themselves can determine this properly. Some uses may prefer a small, thin fonts with a light grey color ...


6

This is taken care of. If you are on the review stats page for a queue where you cant review, you will not be shown the link to review. check out those cool stats! link to review no longer taunts for low rep user


2

This is something we want to do but don’t have a timeline yet. Setting it to status-deferred for now.


5

As you asked this question on multiple exchange sites here is a link to the answer I gave on Stack Overflow. which covers these points from a slightly more technical perspective. Quick Summary of the points raised on Stack Overflow from a non technical perspective Question and Answer sites do not work well with reader views as reader views are designed to ...


19

This is my fault, a side-effect of some infrastucture changes. Sorry. Working on getting a fix out ASAP. For those who are interested in code things: some newly "async" code was not properly "awaited", and the result (now a future/promise, not a value) was handed to a JSON serializer, which duly serialized... the future/promise :( For ...


13

It's not being "cropped". There are literally no child elements in the .tag-suggestions div. Even though the data is being returned.


4

This has been fixed as of the latest round of spoiler fixes. I just missed updating this post at that time. Thanks for the report!


7

Revealing spoilers requires third-party Javascript ... which new users and the paranoid (should) have blocked by default; a bad experience results.


13

I fail to see why a refactoring of the post styling code is applied along with significant changes to that formatting. In my experience it is common wisdom that you refactor your infrastructure first without changing user-facing behavior (as much as this is possible of course), then make behavior changes while resting stably on the new infrastructure. I am ...


53

I propose that the list be modified to something similar to what my ReduceClutter userscript already implements, and it is clearer which link was removed/added, and the new sort order (if it was re-ordered):


9

By adding support for more heading sizes, h1 looks too big now and breaks some older posts: Post: https://stackoverflow.com/a/38025376/3705191 The old h1 size (or # in MD) was closer to the current h2 font size, and the author of the post screenshotted above likely intended it as an h2 heading due to its size. The increase in size changes the intended ...


2

feature-request Can we have the spoilorized text be lighten but not hidden when we are creating a post, editing a post, or in review queues?


12

I made a Google Chrome extension to revert the recent changes to line height, colors, padding, etc. I've included an option to revert the blockquote styling as well. Download Google Chrome Extension Instructions: After installation, click on extension icon (top-right) Under Blockquote styling choose Yellow background


8

bug status-completed There's no way to reveal the spoiler on a user profile. Also, when I hover the mouse on the spoiler's Markdown content while editing the profile, the "Reveal Spoiler" option disappears. This is what I have while editing the profile: And this is when I hover the mouse on the Markdown content:


24

To quote @hkotsubo: Lots of people are saying it's harder to read. You should at least take this into consideration before saying you're done talking about it. I totally agree. It's not only on my laptop, it's worse on mobile too. Although I don't use my mobile very often, I use it enough to make it a problem. From this comment: That's not even just ...


21

Yes, I agree. Please revert the line height back to 1.3! The adjustment to 1.5 is not enough. The lines are still harder to read IMHO.


21

Prid said The new line-height makes it hard to mentally separate paragraphs. I'd like to add that for me, the new spacing makes it very hard to tie even the same sentence together as I try to go from one line to the next. It's so disconcerting and something I've never experienced before, but it makes me give up halfway down a paragraph because I've lost ...


0

The color difference with visited links is unacceptably low, with regard to accessibility. This code: [Sunday Monday](https://example.com) creates this: Sunday Monday Which will normally be #4e82c2 or #3969a4 if visited. Thats only a 10% difference in color: http://colormine.org/delta-e-calculator Compare to the HTML standard #0000ee and #551A8B: https://...


55

The new line-height makes it hard to mentally separate paragraphs. It's difficult to tell from a glance which lines belong to which paragraph, while the old line-height made this very easy to distinguish. Anyways, let's do what we do best as programmers ;) ⭐ Revert Stack Exchange Formatting ⭐ Google Chrome Extension (customizable) Greasemonkey / ...


15

Let's do what we do best as programmers ;) ⭐Revert Stack Exchange Formatting⭐ Google Chrome Extension (customizable) Greasemonkey / Tampermonkey script | (only line-height) Stylish theme (+ Stylus) PLEASE UPDATE SCRIPTS: fixed a bug where the first line in code blocks had small left indent + added old compact paragraph spacing (Sep 1, 2020) Mobile: ...


40

I couldn't agree more with this proposal! I'm all for making the site more accessible - but it should be about making it more accessible for all. There's a fair bit of research showing that increased line spacing can be beneficial for those with certain visual or cognitive impairments (e.g. dyslexia). And I don't dispute that reasoning; what I would say is ...


11

status-review Another user claims that the text has shrunk, while I find the change within acceptable limits on Firefox Android; but on Chrome Android the text is too large compared to how it was previously: As you can see with Chrome, the difference between the size of the post's fonts and (for example) the right column "Linked" list fonts is ...


3

"... with additional refinements to spacing between elements" You may know already, I've read some designer recommend an inter-paragraph margin equal to the line-height -- so that there's exactly one empty line between paragraphs -- the "grid" of lines on the page is perfectly regular, and the inter-paragraph margin is perfectly obvious, ...


17

Let us re-hide spoilers feature-request This seems to have slipped in with a workaround to block re-hiding so links can be clicked and text dragged, see this comment on the matter. This has been fixed. No more ghost clicks of underlying links. Spoilers reveal on any left click anywhere within the spoiler. Clicking again does not re-hide the spoiler (but ...


17

feature-request Additional blockquote refinements. This refinement sounds like de-emphasizing the quote! Instead of de-emphasizing the blockquote, I suggest to differentiate blockquote with normal text by using proper background. I would like to inform about the consensus of users for blockquote formatting by citing: (118 net upvotes) Please revert the ...


Top 50 recent answers are included