Compilation problem!

Just starting out? Need help? Post your questions and find answers here.
Lubos
Enthusiast
Enthusiast
Posts: 167
Joined: Tue Feb 03, 2004 12:32 am
Contact:

Compilation problem!

Post by Lubos »

The program I'm developing has Czech key descriptions. I've been tuning the program for some time now. Today we have a very strange behavior. The IDE program runs without error. After compiling into exe file, the functionality of the program remained, but in all texts every Czech character changed to:

d'z"

One character changes to four characters. :o Maybe I accidentally misplaced something wrong?
Windows 7 Professional / Service Pack 1 - 32bit, PureBasic 5.46 LTS (x86)
My mother tongue is Czech. I have a Czech version of Windows.
Who is not afraid of GOTO, the one need not afraid any things!
User avatar
Shield
Addict
Addict
Posts: 1021
Joined: Fri Jan 21, 2011 8:25 am
Location: 'stralia!
Contact:

Re: Compilation problem!

Post by Shield »

Might be a unicode / ASCII problem, but it's hard to say. You really have to provide some source code example that reproduces the problem.
Image
Blog: Why Does It Suck? (http://whydoesitsuck.com/)
"You can disagree with me as much as you want, but during this talk, by definition, anybody who disagrees is stupid and ugly."
- Linus Torvalds
Lubos
Enthusiast
Enthusiast
Posts: 167
Joined: Tue Feb 03, 2004 12:32 am
Contact:

Re: Compilation problem!

Post by Lubos »

Shield wrote:.......... You really have to provide some source code example that reproduces the problem.
The problem has to be compilation somewhere. I took the old version, which was compiled beforehand without any problems, and now behaves the same way.
The source code is over 4000 rows, and texts are displayed distorted in all program windows.
Windows 7 Professional / Service Pack 1 - 32bit, PureBasic 5.46 LTS (x86)
My mother tongue is Czech. I have a Czech version of Windows.
Who is not afraid of GOTO, the one need not afraid any things!
User avatar
skywalk
Addict
Addict
Posts: 4003
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: Compilation problem!

Post by skywalk »

Close PureBasic IDE.
Open each source file in NotePad++ and verify or set the encoding = UTF-8-BOM.
Then open the PB IDE and make sure to set UTF-8 as default in preferences.
Also check if you changed your compiler options?

Code: Select all

; =================================================
; COMPILER OPTIONS:
;   [ ] Main source file:
;   [ ] Use Compiler:   PureBasic 5.62 (Windows - x64)
;   [x] Use Icon:       C:\myapp.ico
;   [ ] Enable inline ASM syntax coloring
;   [x] Create threadsafe executable
;   [x] Enable OnError lines support
;   [x] Enable modern theme support (for Windows XP and above)
;   [ ] Request Administrator mode for Windows Vista and above
;   [ ] Request User mode for Windows Vista (no virtualisation)
;   Library Subsystem:
;   Executable format:        Windows ;|Console|Shared DLL
;   CPU Optimisation:         All     ;|Dynamic|w/MMX|w/3DNOW|w/SSE|w/SSE2
;   Sourcefile Text encoding: UTF-8
; COMPILE/RUN:
;   [x] Create temporary executable in the source directory
; CONSTANTS:
; VERSION INFO/RESOURCES:
;   Update version info in:   C:\myapp.rc
; IDE PREFERENCES:ToolsPanel:Configuration:Procedure Browser
;   [x] Sort Procedures by name       ;<-- Alphabetical instead of order of appearance. Uncheck when location of Proc desired.
;   [ ] Group Markers                 ;<-- Checked changes ';-!' priority listing.
;   [ ] Display Procedure Arguments   ;<-- Too busy if checked.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Lubos
Enthusiast
Enthusiast
Posts: 167
Joined: Tue Feb 03, 2004 12:32 am
Contact:

Re: Compilation problem!

Post by Lubos »

skywalk wrote:Close PureBasic IDE.
Open each source file in NotePad++ and verify or set the encoding = UTF-8-BOM.
NotePad ++ reports ANSI encoding. In IDE, the Czech text is perfect. Distortion occurs after compilation. That was not the case before. I've probably shaken some settings, but I have no idea where. Switching and converting to UTF-8 has not yet provided me with a good result.
Windows 7 Professional / Service Pack 1 - 32bit, PureBasic 5.46 LTS (x86)
My mother tongue is Czech. I have a Czech version of Windows.
Who is not afraid of GOTO, the one need not afraid any things!
Lubos
Enthusiast
Enthusiast
Posts: 167
Joined: Tue Feb 03, 2004 12:32 am
Contact:

Re: Compilation problem!

Post by Lubos »

skywalk wrote:Close PureBasic IDE.
Open each source file in NotePad++ and verify or set the encoding = UTF-8-BOM.
Then open the PB IDE and make sure to set UTF-8 as default in preferences.
Also check if you changed your compiler options?

An hour after my previous reply:

Your advice was right. I switch to PB 5.62 and I finally succeeded. It also must to delete the info that places the IDE at the end of the PB code. Hurrah. :D
Thank you very much.
Windows 7 Professional / Service Pack 1 - 32bit, PureBasic 5.46 LTS (x86)
My mother tongue is Czech. I have a Czech version of Windows.
Who is not afraid of GOTO, the one need not afraid any things!
User avatar
skywalk
Addict
Addict
Posts: 4003
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: Compilation problem!

Post by skywalk »

Good deal.
I had a similar problem a while back.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Post Reply