Lazarus
Home
Forum
Help
TinyPortal
Search
Login
Register
Lazarus
»
Using the Lazarus IDE
»
Debugger
»
Debugging unicode strings?
Free Pascal
Website
Downloads
Wiki
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
FAQ
Wiki
Bugtracker
Packages
IRC channel
Developer Blog
Follow us on Twitter
Latest SVN
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
Search
Advanced search
« previous
next »
Print
Pages: [
1
]
Author
Topic: Debugging unicode strings? (Read 1411 times)
EganSolo
Full Member
Posts: 135
Debugging unicode strings?
«
on:
February 21, 2017, 12:36:37 am »
Hey guys, how do we setup the watch window to display unicode strings?
I've got a simple program I'm writing to test unicode capabilities. I'm having an issue with the command line display. It won't display the upper case accented A, as in À.
So, I set-up a breakpoint and added two variables to the watch window, this image shows you how they are displayed and the code shows you what I was expecting to see:
Code: Pascal
[Select]
S1
=
'bonjour sérénitàa'
;
S2
=
'sérénitàa'
;
Is there a switch I'm missing to get either GDB or Lazarus or fpc to do the right thing?
Logged
Martin_fr
Administrator
Hero Member
Posts: 4553
Re: Debugging unicode strings?
«
Reply #1 on:
February 21, 2017, 12:48:08 am »
Unfortunately its not implemented.
Logged
Thaddy
Hero Member
Posts: 5771
Re: Debugging unicode strings?
«
Reply #2 on:
February 21, 2017, 08:56:09 am »
Yes. It's a GDB issue too.
But:
For linux console, try
unicode_start
to force unicode mode (most Linux consoles are already UTF8, but just in case)
For windows console, try
chcp 65001
to force unicode mode (or cmd.exe /U )
Alternatively check what your code page is, by typing just chcp. Then you can also adapt your code to use that codepage....
Then run your program. Plz report back if it worked.
«
Last Edit: February 21, 2017, 09:05:42 am by Thaddy
»
Logged
recommends {$macro on}{$define Silly:=ObjFpc}
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Using the Lazarus IDE
»
Debugger
»
Debugging unicode strings?
Recent
[HowTo] Android Developme...
by
HobbyDev
[
Today
at 10:40:00 pm]
An advice - um conselho
by
ezlage
[
Today
at 10:16:30 pm]
how to disable directive
by
Thaddy
[
Today
at 09:01:09 pm]
Terminal Component Availa...
by
BBasile
[
Today
at 08:59:22 pm]
Ubuntu Launcher not using...
by
KarenT
[
Today
at 08:47:34 pm]
FrameBrowser substring pr...
by
Sniper
[
Today
at 08:31:08 pm]
Is there a Bitfield contr...
by
jamie
[
Today
at 08:13:33 pm]
Picture hotspots
by
kapibara
[
Today
at 08:04:22 pm]
[TCocoaMenuItem _setMenuO...
by
skalogryz
[
Today
at 04:43:48 pm]
Insert check mark symbol
by
lainz
[
Today
at 03:32:07 pm]