Tapatalk

Does UltraEdit support Alt+Num codes to insert a Unicode character?

Does UltraEdit support Alt+Num codes to insert a Unicode character?

8
NewbieNewbie
8

PostApr 29, 2022#1

UltraEdit v27.00.0.94

When I try to use an ALT code in UltraEdit (like Alt+26, "→") , a hollow box  appears instead. I have set encoding to UTF-8 for new files. But it doesn't seem to matter. I changed UltraEdit settings to match the advice in this article (Unicode text and Unicode files in UltraEdit) for enabling UTF-8, but still no luck. What am I missing?

6,823625
Grand MasterGrand Master
6,823625

PostApr 29, 2022#2

UltraEdit supports inserting Unicode characters into a UTF-8 or UTF-16 encoded Unicode file by entering its decimal code point value. Pressing Alt plus 2 plus 6 on numeric keypad results in inserting the control character Substitute. How this control character is displayed is a matter of the used font if the used font has defined a glyph for this control character at all which is usually neither displayed nor used in text files.

You reference the Unicode character Rightwards Arrow with the hexadecimal code point value 2192 which is the decimal value 8594. So you have to press Alt plus 8 plus 5 plus 9 plus 4 on the numeric keypad to get inserted this arrow symbol into a UTF-8 or UTF-16 encoded file.

8
NewbieNewbie
8

PostApr 29, 2022#3

That is wonderful news. Thank you so much Mofi  😍

11
Basic UserBasic User
11

PostJun 20, 2022#4

Apologizes if this was covered elsewhere; I know very little about encoding.

For years I've been using what I call "Alt codes" (I think that's the right term). When I hold down the key Alt and type a series of numbers on the keyboard number pad I'll get certain symbols. This avoids me having to go to the character map, find the desired character, select it, copy it, then paste it.

When I use UltraEdit (x64 version 28.20.0.92) and attempt to use certain Alt code, they don't show up. For example, I type the following and I should get the degree symbol: ° (It works here, what do you say now.): Alt+0176. Other Alt codes I use frequently are a bullet symbol, Alt+7, , and arrows, Alt+26, . They all are working here in the entry window for this forum; they also all work in Windows Notepad. However, they don't all work in UltraEdit for me. The degree symbol works, but neither the bullet nor the arrow will show up.

I've tried switching the encoding from ANSI to UTF-8 to UTF-16 for new files, created a new file, and tried the different Alt codes but the only one of the three that works is the degree symbol. However, I just noticed that, for the bullet, Alt+0149 produces the correct symbol in UltraEdit. Alt+7 vs Alt+0149: vs I don't know of an alternate Alt code to get the arrow, however.

I pasted from Notepad to UltraEdit and I got the warning about the format being UTF-8, so I converted and I can see the symbols there in UltraEdit, but when I attempt to create another character using Alt codes I get nothing despite the conversion to UTF-8.

I'm sure UltraEdit can do this, so what am I doing wrong, or what is my misunderstanding about how encoding works?

(website: https://www.branah.com/unicode-converter)

Thanks in advance,

-Matt

6,823625
Grand MasterGrand Master
6,823625

PostJun 21, 2022#5

Matt, please read my post above first.

UltraEdit supports inserting control characters like substitute with decimal code point value 26 into a file while Windows Notepad and browsers translates this entry to the Unicode character Rightwards Arrow with decimal code point value 8594.

The Bullet character has the decimal Unicode code point value 8226 (hexadecimal 2022). So it is necessary to use a UTF-8 or UTF-16 encoded Unicode file and press Alt+8226 to insert a bullet character. Alt+7 inserts the control character Bell. This control character really results in producing a sound output on program supporting sound output at all and interprets this control character according to its real meaning.

If you are using an ANSI encoded file with the code page Windows-1252 (default for North American and Western European countries for Windows GUI applications) as indicated in the status bar at bottom of UltraEdit, there must be pressed nevertheless Alt+8226 to insert the bullet character with decimal value 149 (hexadecimal 95) into the one byte per character encoded text file.

UltraEdit has the ASCII Table view which in real does not contain only the ASCII characters with decimal code point value 0 to 127, but also the sometimes called "extended" ASCII characters according to the default code page for one byte per character encoded text in Windows GUI applications according to the country configured for the used account. In UltraEdit for Windows v28.20.0.92 the ASCII Table view can be opened by clicking on eight ribbon tab Layout in second group Views on the check box item ASCII table or in toolbar/menu mode with contemporary menus in menu Layout on menu item ASCII table or in toolbar/menu mode with traditional menus in menu View in submenu Views/lists on menu item ASCII table. A hotkey or chord can be assigned to the command ASCII table in the Key mapping configuration dialog to quickly toggle the visibility of this view by key. A character displayed in this view can be inserted into active file at active caret position with a double click on the character. The bullet character is in this list on using Windows-1252.

Special hint: It is most efficient to use macros to insert often needed characters with a hotkey or chord assigned for fast execution by key with all the macros stored together in one macro file which is configured to be loaded by UltraEdit already on startup.

For example: A macro with name Bullet consists of the following code:

Code: Select all

IfExtIs "html"
"•"
ExitMacro
EndIf
IfExtIs "htm"
"•"
ExitMacro
EndIf
IfExtIs "xhtml"
"•"
ExitMacro
EndIf
"•"
This macro inserts on execution the HTML entity • into the active file on having case-insensitive the file extension html or htm or xhtml and the bullet character into all other files. There is assigned the chord Alt+Shift+V B for this macro.

There is another a macro with name Right arrow with the following code:

Code: Select all

IfExtIs "html"
"→"
ExitMacro
EndIf
IfExtIs "htm"
"→"
ExitMacro
EndIf
IfExtIs "xhtml"
"→"
ExitMacro
EndIf
"→"
This macro inserts on execution the HTML entity → into the active file on having case-insensitive the file extension html or htm or xhtml and the rightwards arrow character into all other files. There is assigned the chord Alt+Shift+V R for this macro.

The two macros are both stored in the macro file SpecialCharacters.mac which is configured to be automatically loaded by UltraEdit on startup. Then it is possible to press quickly Alt+Shift+V and next the key B or R to insert the bullet or rightwards arrow entity/character. The multi-key delay can be configured in the key mapping configuration dialog window.

There is also the Macro List view to execute a macro by clicking on the name of a macro in this list.

Another possibility on not needing to insert an HTML entity or the character depending on the file extension of active file is making use of the Tag List view and create a tag group like Special characters with one tag for each special character for the often needed special characters, i.e. your own favorite characters list. Press Ctrl+F8 (default hotkey for command Tags) to open the Tag List view and select the tag group HTML - Special Characters to get an impression of this feature.

Further, smart templates can be also defined to insert special characters like bullet or rightwards arrow which makes it possible to type in file the name of the smart template (character name) and UltraEdit suggests inserting the template (special character) on user pressing key TAB or RETURN or ENTER.

3
NewbieNewbie
3

PostJan 29, 2025#6

Well, all the information here seems well. However, I have been using UltraEdit for some time now, have used the Alt+ to insert character codes into my cmd commands, I always put in echo (followed by) Alt+007 after the cmd program is finished backing something up or the program is finished, that code make a tiny little box in the code when looking at it that makes the PC system put on a little bell sound to let operator know the program finished. Since UltraEdit update, now when I press the Alt key to insert the code, the Alt key just highlights all the little boxes on the top of all the menu boxes for the editor for shortcut keys for the editor. I have no idea why it has changed to doing that instead of allowing me to enter the Alt codes. I cannot enter them because UltraEdit thinks I am trying to use Alt shortcut keys and not enter Alt+ codes...uhhh maybe I will have to go back to earlier version, I am at a loss.  Any ideas or thoughts appreciated.

6,823625
Grand MasterGrand Master
6,823625

PostJan 29, 2025#7

It is the GDI+ library of Microsoft used by UltraEdit for Windows which results in showing the shortcut keys (mnemonic keys to be precise) in ribbon mode for execution of a command by key or setting the input focus to the main menu in a toolbar/menu mode or back to the document window area on pressing just left Alt and leave the key without pressing another key.

It is still possible to press and hold left Alt and quickly type the decimal code point value of a Unicode character on the numeric keypad to insert into the file the appropriate Unicode character according to the Unicode specification. That works for all Unicode characters beginning from normal space (Alt+32). It works also for some control characters with a code point value less than decimal 32 like backspace (Alt+8) or horizontal tab (Alt+9).

It is right that inserting a control character usually not present in a text file like the bell character is not inserted on pressing Alt+7 or Alt+007. I do not know the reason why those control characters cannot be inserted with the Alt+number method anymore.

However, there is the ASCII table. Click on ribbon tab Layout on the check box ASCII table to get it displayed. Double click on the character with name BEL and the control character with code point value 7 is inserted into the text file at current position of the caret (text cursor). The ASCII table view can be configured with a click on the pin symbol to auto-hide and get displayed when moving the mouse pointer over the tab of the view displayed on being auto-hidden docked on left or right side of the main application window.

Another method to insert the bell character is clicking on ribbon tab Edit in the group Insert on the down arrow of the command Insert item for opening the popup menu and clicking next on menu item Literal character. There is shown by default a message box informing the user how to use that command. Click on button Insert. Then press Ctrl+G to insert the bell control character. This method can be simplified by assigning in the Key mapping configuration dialog a hotkey to the command Literal character and of course click on the check box Don't show this window again. Then pressing the hotkey for the Literal character followed by Ctrl+G inserts the bell control character.

It would be also possible writing a small UltraEdit script added to the Scripts list with a hotkey which inserts the bell control character into the active file by pressing the associated hotkey. There can be written also a small UltraEdit macro stored in a macro file being configured for automatic load on startup with an assigned hotkey to insert the bell control character into the active file by pressing the hotkey of the macro.

I recommend for all readers visiting this topic reading the Wikipedia page about Alt code for getting knowledge how entering characters using Alt and a numeric value works on modern operating systems in modern Unicode aware applications.

3
NewbieNewbie
3

PostJan 30, 2025#8

Thank you Mofi, I will look at these settings (or learn to type faster … lol). I could always take my time pressing Alt+007 before update and it would always put in the bell control character. So my programs could give the sound message to operator that the task was finished. I am guessing you are more likely correct on the settings, but will check all your tips out. Thank you for the feedback.

PostJan 30, 2025#9

Well, after searching through Windows 11 and UltraEdit, taking into consideration the GDI+ library of Microsoft, delving into ribbon mode, turning menus upside down and sideways, inside out and back again, I went into the Advanced - Settings, there I found at Editor - Advanced the Allow low ASCII values to be entered (usually control codes) check box which was no longer checked … rofl. I think, this is the first time UltraEdit on an update has not kept my settings as they had been, who knew.

Thank you everyone here and on other forums, all the information was great and will be kept for future use, will check that box is checked in the future updates.