Page 1 of 2
Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:11 pm
by highend
Hi,
something's very odd atm...
PureBasic v6.21 x64 (IDE), Compiler: v6.04 LTS x64
Code:
Code: Select all
Debug "D:\250807_Analyse_Bereinigung_Pfadlängen_Files.txt"
The .pb file is UTF-8 with BOM.
I get this output:
Why is that?
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:39 pm
by infratec
It does exactly what it should.
It prints the string which you added behind.
What does you expect?
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:42 pm
by highend
No it doesn't
The string to output contains "ä" but the output doesn't display an "ä" but an "a" followed by an "n" with some dots above it
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:47 pm
by infratec
My output looks like this:
D:\250807_Analyse_Bereinigung_Pfadlängen_Files.txt
What language is used for the IDE? In my case it is german.
And in settings, what is your font for the debug window? I use consolas west
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:49 pm
by Fred
Is your file in UTF-8 format ? You can check in Menu File -> File Format -> UTF8
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:55 pm
by highend
What language is used for the IDE? In my case it is german.
And in settings, what is your font for the debug window? I use consolas west
My IDE is set to english and the (custom) font used for the debug window is Consolas (which never had issues to display german special chars). Changing it to Segoe UI doesn't change the weird display of that string.
Is your file in UTF-8 format ? You can check in Menu File -> File Format -> UTF8
Yes it is. Encoding: Utf8
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 12:59 pm
by infratec
What's the output if you open a new code window and put this debug line inside, without anything else?
(That's what I did)
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:03 pm
by highend
Still the same output

Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:05 pm
by infratec
That's very strange, because here it works correct.
Forget the following...
In reality, the path is in a variable isn't it?
Use
Code: Select all
ShowMemoryViewer(@path$, StringByteLength(path$))
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:06 pm
by Fred
Tried here with consolas as well and it works as expected. Strange issue for sure !
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:08 pm
by infratec
Or please try that:
Code: Select all
path$ = "D:\250807_Analyse_Bereinigung_Pfadlängen_Files.txt"
Debug path$
ShowMemoryViewer(@path$, StringByteLength(path$))
61 00 64 00 6C 00 E4 00 6E 00 67 00 65 00 6E 00 a.d.l.ä.n.g.e.n.
The ä is represented by 00 E4 (E4 00)
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:11 pm
by highend
When I change it to "String View (Unicode)" the output is correct (as well in Hex View)^^
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:13 pm
by Kiffi
Just a guess: Did you copy the path from somewhere into the clipboard and paste it into the IDE? What happens when you type
?
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:15 pm
by infratec
Please use 'Hex' so that the codes of the characters are visible.
Re: Strange outpug from debug?
Posted: Mon Sep 01, 2025 1:25 pm
by highend
Just a guess: Did you copy the path from somewhere into the clipboard and paste it into the IDE? What happens when you type
The guess is correct...
When I copy your "äöüÄÖÜ" here from the forum into the IDE, the output is correct, when I do the same with the path I posted, it is shown correctly. If i copy it out of the my editor (Sublime Text) or from the file manager, it's not correct...