Search found 4331 matches

by freak
Wed Feb 11, 2026 10:15 pm
Forum: Feature Requests and Wishlists
Topic: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line
Replies: 8
Views: 1478

Re: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line

What you may want to do is wrap your code in a DisableDebugger block. This way the debugger will not know the lines inside the code block and triggering a warning/error will appear as though it happened on the last line before entering the disabled section (usually this is the caller of the ...
by freak
Sat Feb 07, 2026 5:09 pm
Forum: Feature Requests and Wishlists
Topic: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line
Replies: 8
Views: 1478

Re: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line

What if there are other errors along the way? Do we ignore those, or do we ignore the original one? Or do we claim they both happened at the outer location? Or do we stop at the innermost error and just remember somewhere that at some point in the future we have to stop and show another error? What ...
by freak
Fri Feb 06, 2026 9:03 pm
Forum: Feature Requests and Wishlists
Topic: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line
Replies: 8
Views: 1478

Re: Optional step out index for DebuggerError() and DebuggerWarning() to highlight the calling line

The problem especially with DebuggerError() is that it will stop execution while inside the DebuggerError() command, so if you continue/step after the error, it will also continue on the next line after this command. Highlighting a different line than the one with the command would be very confusing ...
by freak
Sun Feb 01, 2026 1:08 pm
Forum: Announcement
Topic: PureBasic 6.40 beta 1 is ready, surprise inside !
Replies: 153
Views: 35147

Re: PureBasic 6.40 alpha 1 is ready, surprise inside !


The problem is spreading this code as a "tip" around the forum, which will lead to people blindly using it thinking they are doing a clever optimization without understanding the details. And then if we do change something, we have to deal with the complaints again. And all that for an ...
by freak
Fri Jan 30, 2026 9:16 pm
Forum: Announcement
Topic: PureBasic 6.40 beta 1 is ready, surprise inside !
Replies: 153
Views: 35147

Re: PureBasic 6.40 alpha 2 is ready, surprise inside !


this is good news; but perhaps a next step is 4 or 8 byte alignment for string buffers such that copy operations can work faster; as an idea. It's a trick I've used.


That should already be the case. The default alignment for allocated memory is 8byte for x86 and 16byte for x64. Adding the space ...
by freak
Thu Jan 29, 2026 9:52 pm
Forum: Announcement
Topic: PureBasic 6.40 beta 1 is ready, surprise inside !
Replies: 153
Views: 35147

Re: PureBasic 6.40 alpha 1 is ready, surprise inside !

And frankly speaking, you shouldn't take freaks comment too serious.
I mean, where else would you store the length of the string or what else would you like to store internally in a string in future?
Tinkering with internals always carries a risk to break in future, no question, but here I have no ...
by freak
Tue Jan 27, 2026 7:50 pm
Forum: Announcement
Topic: PureBasic 6.40 beta 1 is ready, surprise inside !
Replies: 153
Views: 35147

Re: PureBasic 6.40 alpha 1 is ready, surprise inside !


Or by using fryquez ResetStringLength procedure/macro: https://www.purebasic.fr/english/viewtopic.php?p=650721#p650721

CompilerIf #PB_Compiler_Version >= 640
Declare ResetStringLength(*s.Character)

Procedure ResetStringLength(*s.Character)
Protected *p.Integer = *s -SizeOf(Integer)
*p\i ...
by freak
Sat Jan 24, 2026 8:48 pm
Forum: Coding Questions
Topic: Long bug when negative bit is set
Replies: 11
Views: 6821

Re: Long bug when negative bit is set

This is fully correct. No bug.

PB uses arithmetic shift, as mentioned in the documentation: https://www.purebasic.com/documentation/reference/variables.html

More details: https://en.wikipedia.org/wiki/Arithmetic_shift

If you want to avoid repeating the sign bit with a shift right, mask out the ...
by freak
Sat Jan 24, 2026 12:06 pm
Forum: Announcement
Topic: PureBasic 6.40 beta 1 is ready, surprise inside !
Replies: 153
Views: 35147

Re: PureBasic 6.40 alpha 1 is ready, surprise inside !

Using Win32 API with Space() for example will require an extra PeekS().

Not sure what this means, either. I do this in my app, so are you saying I can't do this anymore without PeekS() now?

cap$=Space(999) : GetWindowText_(hWnd,cap$,999)


Just like this:
cap$=Space(999) : GetWindowText ...
by freak
Wed Jan 14, 2026 8:24 pm
Forum: Announcement
Topic: PureBasic 6.30 is out !
Replies: 187
Views: 68793

Re: PureBasic 6.30 is out !




mk-soft , not all bugs is fixed.
For example, bug HeaderSection / EndHeaderSection is not fixed https://www.purebasic.fr/english/viewtopic.php?t=87517
Maybe it will be fixed in PB 6.31.


A bugfix is here now: https://github.com/fantaisie-software/purebasic/pull/340

You can build a fixed ...
by freak
Tue Jan 13, 2026 10:56 pm
Forum: Announcement
Topic: PureBasic 6.30 is out !
Replies: 187
Views: 68793

Re: PureBasic 6.30 is out !


mk-soft , not all bugs is fixed.
For example, bug HeaderSection / EndHeaderSection is not fixed https://www.purebasic.fr/english/viewtopic.php?t=87517
Maybe it will be fixed in PB 6.31.


A bugfix is here now: https://github.com/fantaisie-software/purebasic/pull/340

You can build a fixed IDE ...
by freak
Sun Nov 16, 2025 3:14 pm
Forum: Bugs - Windows
Topic: DashPath() does not scale correctly
Replies: 3
Views: 2659

Re: DashPath() does not scale correctly

Lebostein wrote: Thu Oct 30, 2025 7:24 am Seems the problem is Windows-only. On macOS, both examples work as expected.
Yes. This is a GDI+ bug that I could not find a workaround for that works in all cases. The problem is also the cause of this bug report: viewtopic.php?p=515364
by freak
Sun Oct 26, 2025 9:25 pm
Forum: Coding Questions
Topic: Vector fonts not scaled properly to printer
Replies: 6
Views: 4700

Re: PB 5.50b2 - vector fonts not scaled properly to printer

This is not a bug in my opinion.

If you use VectorFont() without a Size parameter, the original Size from LoadFont() is used, but interpreted in Points, not in your current output unit (in this case Pixels).

If you use VectorFont() with the size parameter then that parameter is interpreted in your ...