Sublime Forum

Special characters in HTML

#1

When I’m editing an HTML document (or other similar file types–PHP, Markdown, etc.), special characters don’t seem to work correctly. I’m trying to type in the Windows Alt-code for accented characters, etc., and I get the wrong characters. When I type Alt-0232, for instance, I should get è. Instead I get Φ. Alt-0146 should give a curly apostrophe ( ), and instead it gives a period. If I change the file type to Plain Text, Javascript, Python, or most other types, these kind of shortcuts work properly.

Any idea what would be causing this, and how to fix it?

ST3 on Windows 10.

0 Likes

#2

i would LOVE to be able to create a new bug report but the window that pops up to create the new posting has important/required fields above the top of my display and nothing i do will bring them back into view. i have NO way to post any new topics!
It would be MUCH nicer if this forum did not have stupid pop up windows to edit the new posting into. a simple editable WEB PAGE would be much more reliable than a popup which is always an extreme annoyance no matter what actual name it is given. its a popup and thus its annoying.
because I cant actually create a new posting i am instead forced to hijack someone else’s thread just to be able to post.
< /rant >
sublime text 3 does not display UTF8 characters properly
┏━━━━━━━┓
┃XXXXXXX┃
┗━━━━━━━┛

the above “box” drawn with utf8 characters in a source file shows as

┏━━━━━━━┓
┃XXXXXX┃
┗━━━━━━━┛

or
┏━━━━━━━┓
┃XXXXXXXX┃
┗━━━━━━━┛
had to edit the spaces into X’s because this STUPID forum software strips multiple spaces which i srsly do not understand! PLEASE switch to forum software that “just works ™”
depending on how many spaces i inject into the blank space.
this forum edit window also does not display them correctly either. there is supposed to be an identical number of blank spaces in the middle of the box as there are horizontal bars across the top.
in st3 there is no way to properly draw this single line box but the double line box chars display 100% correctly.

0 Likes

#3

It will just work…if you put them in code blocks:

┏━━━━━━━┓
┃XXXXXXX┃
┗━━━━━━━┛

Source:

```
┏━━━━━━━┓
┃XXXXXXX┃
┗━━━━━━━┛
```
1 Like

#4

What encoding does your html file use? Have you tried reverting to a freshly installed state?

0 Likes

#6

You not being able to correctly use the forum software doesn’t mean it’s broken. That said, I’d like to ask you for a somewhat more kindly tone.

Copy & pasting your code example into a freshly installed ST3 on Winodws …

grafik

It looks very well, to me.

If it doesn’t do so, it may be related with the font you are using. Some fonts may not be of 100% fixed width, means some code points render wider than others. I’ve seen that with ligatures or emoji for instance.

That’s barely something ST to blame for.

1 Like

#7

@bschaaf - Your comment did prompt me to systematically remove things till I found the culprit. It was a wonky keyboard shortcut I had created. I’m still not sure what in that key binding was causing this behavior, but I can easily live without the shortcut, so it’s fixed. Thanks for your help.

By the way, “i would LOVE” to be able to delete this entire thread, since some asshat took it over with his complete nonsense. Sadly, I’m not able, whether because I’m a noob or because that’s just not allowed here. But oy, how I would LOVE to.

0 Likes

#8

ok so the tone in my writing was a direct result of NOT being able to post a clean thread simply because the form to create a new thread, just like this reply form is a POPUP WINDOW and while this window is entirely within the bounds of my visible browser view the form to create a new thread has very important fields above the top of the view - there is literally NO WAY for me to edit those fields! That IMHO makes the forum software BROKEN in a HUGE WAY!!

as for “it works for me” it does not work for me but maybe thats a font issue as you say!

The right edge of the middle lines of the box do not align with the right edge of the top or bottom lines of the box no matter what I do. Im in Lunux, using “subpixel_antialias” and “font_size”: 12 in my config. I did not set a specific font so what ever the default is there is what I’m using.

also, look at that box again but replace the X’s with the same number of spaces.

0 Likes

#9

ok so the tone in my writing was a direct result of NOT being able to post a clean thread simply because the form to create a new thread, just like this reply form is a POPUP WINDOW and while this window is entirely within the bounds of my visible browser view the form to create a new thread has very important fields above the top of the view - there is literally NO WAY for me to edit those fields! That IMHO makes the forum software BROKEN in a HUGE WAY!!

What browser/version are you using? As far as we’re aware this site has no problem with any major browsers and works fine across mobile and desktop.

The right edge of the middle lines of the box do not align with the right edge of the top or bottom lines of the box no matter what I do. Im in Lunux, using “subpixel_antialias” and “font_size”: 12 in my config. I did not set a specific font so what ever the default is there is what I’m using.

This would be due to your system’s monospace font not having monospace glyphs for the unicode characters you’re using. Anti-aliasing options and font size generally don’t affect that. Here’s what it looks like under Ubuntu 20.04:

Screenshot%20from%202021-03-06%2016-38-57

0 Likes

#10

what font are you using in st3?
im using the latest firefox from gentoo linux
laptip has display is 1920x1080 and even maximiizing the browser the top of the form was pushed above the top of the view.
p.s. they glyphs display just fine when written to the terminal (gnome terminal)

0 Likes

#11

The default monospace font on ubuntu is Ubuntu Mono Regular. Note terminals may alter glyphs to make them fit.

In terms of the website, perhaps you have an extension interfering? This is on linux firefox:

0 Likes

#12

I guess this thread has been hijacked a bit, but I also have problems with this forum on Chrome on Android in landscape mode, maybe due to a low res screen or something, but there is no way to see what I am typing with the virtual keyboard (Swiftkey in this case) open - I can only scroll the thread replies, not my textarea where I am composing a reply. Ironically, I don’t have enough RAM on this tablet to attach the screenshot from the gallery… (the Chrome tab reloads as it was closed to free memory) I will copy it to my computer later and upload it from there.


For reference, my device is a Huawei Mediapad T3 10 (AGS-L09)

0 Likes

#13

the only plugin i have is uBlock Origin and there/s no way im either uninstalling that or disabling it lol. Also im not certain that that would be causing this issue.
ill poke around with font settings in my st3 configs to see if the glyphs align.
tyvm for the help

0 Likes