Search found 465 matches

by Sicro
Thu Dec 21, 2023 7:02 pm
Forum: Coding Questions
Topic: Improving performance of byte pointer copy
Replies: 19
Views: 1151

Re: Improving performance of byte pointer copy

@Oso It would be better if you included a test code with console output instead of debug output, so that not everyone has to adapt your code to experiment with it and measure the speed correctly. Please note that PeekS() requires the character length: PokeS(*dest, cpstring.s, lendata.i / 2, #PB_Str...
by Sicro
Thu Dec 07, 2023 8:23 pm
Forum: Announcement
Topic: PureBasic 6.04 LTS is out !
Replies: 78
Views: 11542

Re: PureBasic 6.04 beta 2 is out !

Added /DLLPROTECTION flag in commandline and a switch in 'Compiler options' to enable DLL preloading protection Perfect! This means my portable app can actually be portable again, and not rely on files located in other folders. Even with DLL protection activated, your app should be portable. There ...
by Sicro
Mon Oct 16, 2023 6:53 pm
Forum: Coding Questions
Topic: SOLVED : centering a dialog in an app
Replies: 9
Views: 653

Re: SOLVED : centering a dialog in an app

This is how I did it in an old program of mine. If the window #Window_Main was moved partially out of the screen, it does not work. Then the message requester is in the middle of the screen again. Enumeration Window #Window_Main EndEnumeration Enumeration Gadget #Button_Show_MsgBox EndEnumeration Gl...
by Sicro
Sun Sep 17, 2023 6:52 pm
Forum: Bugs - Documentation
Topic: Missing PBCompiler parameters
Replies: 7
Views: 2585

Re: Missing PBCompiler parameters

On Windows: > pbcompiler --version PureBasic 6.03 beta 8 LTS (Windows - x64) - (c) 2023 Fantaisie Software > pbcompiler --help pbcompiler "Filename" Command switches: -------- /DEBUGGER: Enable the debugger /OUTPUT "Filename": Create an executable or a dll to the given filename ...
by Sicro
Tue Aug 22, 2023 6:31 pm
Forum: Coding Questions
Topic: Copy Paste gadget editor
Replies: 6
Views: 548

Re: Copy Paste gadget editor

and under linux? It is always an advantage to specify in your initial question for which operating system you are looking for a solution. Here is a sample code for Linux: http://www.chabba.de/Linux/EditorGadget/Editor_ClipboardOnCommand.pb Select text in the EditorGadget and press the left button a...
by Sicro
Sat Aug 12, 2023 10:48 am
Forum: Bugs - Linux
Topic: 'CompilerEndIf' without 'CompilerIf'
Replies: 4
Views: 986

Re: 'CompilerEndIf' without 'CompilerIf'

Yes, juergenkulow, that is the minimal code I had as well. As you also write, the error only occurs sometimes with this one. With the complete code I always get the error. But probably the minimal code is still helpful to track down the problem, thanks for posting.
by Sicro
Fri Aug 11, 2023 12:49 pm
Forum: Bugs - Linux
Topic: 'CompilerEndIf' without 'CompilerIf'
Replies: 4
Views: 986

'CompilerEndIf' without 'CompilerIf'

PureBasic: 6.03 beta 4 LTS (Linux - x64) Linux: Manjaro x64 I have tried to create code that is reduced to the minimum and still causes the error, but unfortunately these did not always reliably cause an error (for example, when the compiler was restarted, then the code suddenly worked without error...
by Sicro
Tue Aug 08, 2023 5:02 pm
Forum: Coding Questions
Topic: [solved] #PB_OS_Linux_GuiToolKit
Replies: 2
Views: 355

Re: #PB_OS_Linux_GuiToolKit

... to be able to determine which GUI toolkits are installed in the operating system on which the program is running? Are you aware that all three GUI toolkits can be installed at the same time? If you want to determine at compile time which subsystems are specified in the compiler options there is ...
by Sicro
Fri Jul 21, 2023 1:47 pm
Forum: Coding Questions
Topic: Ucase() fails with UTF
Replies: 23
Views: 1532

Re: Ucase() fails with UTF

@Torf

What are the outputs for the following code?

Code: Select all

Debug Asc("ñ")
Debug Asc(UCase("ñ"))

Code: Select all

; Download from https://dnscope.io/idlefiles/UTF16.pb
IncludeFile "UTF16.pb"

Define text$ = "ñ"
UTF16::StrUCase(text$)
Debug text$
by Sicro
Sat Jul 15, 2023 2:57 pm
Forum: Coding Questions
Topic: Ucase() fails with UTF
Replies: 23
Views: 1532

Re: Ucase() fails with UTF

But I am not sure the first link is perfect (however unicode.org it is a very strong reference). [...] I think it is an adaptated page, but not a perfect reference page. It is the official site of the Unicode Consortium. If you know a better reference site, please name it. I think for the misconcep...
by Sicro
Fri Jul 14, 2023 1:32 pm
Forum: Coding Questions
Topic: Ucase() fails with UTF
Replies: 23
Views: 1532

Re: Ucase() fails with UTF

I think this link will clear up the misconceptions here about Unicode:

General questions, relating to UTF or Encoding Form

When we talk about Unicode in PureBasic, we generally mean UCS-2. This is how Unicode strings are officially encoded in PureBasic.
by Sicro
Sat Jul 08, 2023 4:10 pm
Forum: Bugs - IDE
Topic: PB-IDE (x64): ToolsPanel Explorer crashes
Replies: 5
Views: 2491

Re: PB-IDE (x64): ToolsPanel Explorer crashes

OS: Manjaro Linux x86_64 DE: Xfce 4.18 WM: Xfwm4 $ purebasic -v PureBasic IDE 6.03 beta 3 LTS [devel; cdfd42d7a3d8; 07-07-2023] - (c) 2023 Fantaisie Software Started PureBasic IDE in the terminal, then clicked on "Persönlicher Ordner" in the explorer inside the tools panel and the PureBas...
by Sicro
Mon May 08, 2023 10:19 pm
Forum: Tricks 'n' Tips
Topic: utf16 string module StrCmp full case folding
Replies: 28
Views: 2934

Re: utf16 string module StrCmp full case folding

I mistakenly wrote CaseMapping.txt in the previous post (does not exist), correct is UnicodeData.txt . It uses the 1st instance so if it sees a repeat key it ignores it. Yes, that's what I thought, that's how your code works. But you can't be sure that the 1st instance is always the right one. 01c4 ...
by Sicro
Mon May 08, 2023 7:59 pm
Forum: Tricks 'n' Tips
Topic: utf16 string module StrCmp full case folding
Replies: 28
Views: 2934

Re: utf16 string module StrCmp full case folding

The CaseFolding.txt file is not suitable for converting lowercase letters to uppercase or vice versa. This file is for normalizing two strings (reducing character variants; called case-folding) so that they can then be compared. For converting lowercase to uppercase or vice versa, the CaseMapping.tx...
by Sicro
Sat Apr 01, 2023 12:22 pm
Forum: Applications - Feedback and Discussion
Topic: RegEx engine module that builds NFA/DFA and uses it for matching
Replies: 6
Views: 1039

Re: RegEx engine module that builds NFA/DFA and uses it for matching

Finale 1.0.0 released After some testing and improvements, I have now decided to release the final version 1.0.0 Download: Click New Added ASCII mode, which restricts the predefined character classes to ASCII characters only (encoding is still UCS-2) and restricts case-insensitive mode to uppercase...