Search found 14 matches

by guido
Thu Nov 10, 2005 1:32 pm
Forum: The PureBasic Editor
Topic: Syntax highlighter for vim - Now Available V2!
Replies: 17
Views: 9397

Re: Syntax highlighter for vim - Now Available V2!

Nice to know, that somebody else uses vim for pb; i posted a syntax file quite some time ago at vim org (where it is still avaliable) and also mentioned it here, but since neither a vote there nor any feedback arrived, I didn't dare to upload the version containing the keywords missed the first time ...
by guido
Mon Jul 19, 2004 10:13 am
Forum: General Discussion
Topic: XSL Help
Replies: 3
Views: 1522

The non-English characters should be easy to fix: add an encoding="ISO-8859-1" attribute to the XML tag.

If generating HTML text-like stuff, I recommend using the <xsl:text> tag; of course one has to quote it, so &nbsp; will transform to &nbsp; but it should work and is only ugly, not difficult.
by guido
Wed Jul 14, 2004 4:40 pm
Forum: General Discussion
Topic: Does PB short-circuit expressions?
Replies: 17
Views: 5011


Short circuit evaluation is a good thing. It means you don't need to evaluate both sides of a logical expression to get the result. Therefore if you have a simple comparison logically combined with an evil complex one, you're best putting the simple one on the left because it may mean you can ...
by guido
Mon Feb 23, 2004 4:28 pm
Forum: Feature Requests and Wishlists
Topic: [Implemented] Random with max, min and type
Replies: 5
Views: 2386



Yes - thanks... It's just what I'm doing right now... But if you want very small number it is a lot of typing. For example... If you want a random number between 0.006 and 0.008.

Debug ((Random(1000) *0.002)/1000 + 0.006)

Have you considered to write a function for it :wink:? I would hate to ...
by guido
Tue Jan 27, 2004 9:25 am
Forum: Feature Requests and Wishlists
Topic: ForNext "Autostep"
Replies: 25
Views: 5642

@GPI, @GedB, @Dare2: Let me join the club! :D
votes for: Step (expression)

And puts in a plug for SGN and NOT

:)
I couldn't have summarized it better. A new keyword just for blurring the sign of the step width seems overkill. TOWARDS is a very naturally sounding suggestion, but since AUTOSTEP ...
by guido
Mon Jan 26, 2004 11:16 am
Forum: Feature Requests and Wishlists
Topic: ForNext "Autostep"
Replies: 25
Views: 5642

i consider for / next to be something simple and quick to create loops, i'd go for while / wend for anything more complex
In the extreme you could substitute all loops by if and goto :wink:. Striving for a code reflecting the problem it's out of question, that the purpose of a for loop is building ...
by guido
Mon Jan 26, 2004 9:12 am
Forum: Feature Requests and Wishlists
Topic: ForNext "Autostep"
Replies: 25
Views: 5642

Sign function would help, but...

The ugly aspect of AUTOSTEP is, that it adds a keyword for a single scenario. (It wouldn't work at all in Pascal where TO a DOWNTO are distinct keywords.) Typically the problem is solved with the arithmetic sign function available as SGN in ancient BASICs.

Given that this function is missing in PB ...
by guido
Thu Jan 15, 2004 4:18 pm
Forum: Feature Requests and Wishlists
Topic: (Compiler Option) In-Memory source files.
Replies: 17
Views: 4419

A couple of reasons. You write to the ram disk, and people can still see the sources. Ive already thought of that :) Right now, it spits out my custom code into a pb file before compile, and run the code with the user's code through the compiler, and then deletes the custom code. This is a huge ...
by guido
Mon Jan 12, 2004 12:41 pm
Forum: Feature Requests and Wishlists
Topic: Renaming of a few Functions
Replies: 20
Views: 5174

Re: Not really a function - but what about EndWhile for WEND

Yes, could be...
...but While ... Wend Loops are a standard in programming languages. Why force the advanced user to learn a new commandname? In the end it's an aliteration, W hile W end, that alone is worth keeping it the way it is ;-)
Of course its an alliteration, but its the only one to be ...
by guido
Mon Jan 12, 2004 10:04 am
Forum: Feature Requests and Wishlists
Topic: Renaming of a few Functions
Replies: 20
Views: 5174

Not really a function - but what about EndWhile for WEND?

This is only for symmetry and consistency reasons, but given Interface / EndInterface, Procedure / EndProcedure, Enumeration / EndEnumeration etc I consider EndWhile much nicer than WEnd which in turn reflects the meaning still a notch better than Wend...
by guido
Wed Jan 07, 2004 8:08 pm
Forum: Feature Requests and Wishlists
Topic: New Constants...
Replies: 24
Views: 7875

Pre-canned constants are a suboptimal solution

While of course having a resident file containing all that stuff is a solution, the example in a previous reply already showed, that the control character is not the final destination but an intermediate one like in

"text1" + #CR + "text2"

There is also not much advantage of looking up a value in ...
by guido
Mon Dec 01, 2003 11:38 am
Forum: The PureBasic Editor
Topic: Vim Syntax file
Replies: 0
Views: 2142

Vim Syntax file

While I found a vage announcement for such a file, I couldn't find the real thing. Since standard basic syntax looks awful (treating all constants and everything to end of line as somethig else) I did it myself and uploaded it to http://www.vim.org. Greetings
by guido
Fri Nov 28, 2003 12:20 pm
Forum: The PureBasic Editor
Topic: Continuation line for source file
Replies: 47
Views: 33055


Wouldn't that make a mess of bug hunting?!?
I mean.. then the error could point to 30 lines below the actual equation (coz that's where the next parenthesis is)?!?


Actually it's not so much of a problem, because something has to fill these 30 lines. Any <b>statement</b> (like: if, repeat) is ...
by guido
Fri Nov 28, 2003 10:02 am
Forum: The PureBasic Editor
Topic: Continuation line for source file
Replies: 47
Views: 33055

Continuation Lines

I tuned in late, but it seems the discussion is bypassing the most important points.
- It's quite academic to think about dividing keywords
- a continuation character is a kludge, a very low level solution, which may be the simplest to implement but has no other advantages.
- long lines are easily ...