Qbasicnews.com

Full Version: A question on keyword Syntax section
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
OK, I've looked at this a few different ways (look at the page history) and I have to question the way it is now.

Looking at the ABS keyword as an example http://www.freebasic.net/wiki/wikka.php?wakka=KeyPgAbs.

Vic said to include overload operators and gave an example of syntax that looked like
Code:
function ABS (byval number as integer) as integer

That is showing how you would declare it as a new function (if there were no ABS function), but I've always taken syntax to mean how you use it. If you look at VB's, QB's, C, etc documentation it gives it similar to the way I have it now.
Code:
ABS ( number )

And then in the descript go on to say that ABS will take any valid numberic expression....etc etc etc (although a note should be add about if you try to take the ABS of U-data type like UBYTE)

I know this isn't VB or QB or anything other than FB, but we can learn from their examples.

The Question then becomes, should we define the syntax to be 'what it is' (a.k.a. Vic's first example) or the 'way it is used' (a la most other languages documentation style)?

Also, is there going to be a 'result' section under the example section, or will the results of the example just be in the example section (as it is now with the ABS). I noticed that a version of the format tut had this.
I didn't write that one, but I think (number) would work, if you add an attribute to the table about what it returns.
I agree, the ABS ( number ) should do fine, with an explatin in the argumetns secton that number can be any numeric value or any numeric variable type.
OK, now are we using the format that Vic put up with the FBTags )e.g. the ABS keyword page), or are we using the format that's under the Sample Style Page?

Personally I like the sample style page, but I'm fine with either.
They are basicly the same style, You could use either, though (as the author of the sample) I like the SampleStyle more Wink
No, don't use either. Stick with one. I like the sample style page.
Well, if it will easier to new users, let's do that way, but the QB-ish declarations will be needed in some cases, when arguments are optional and take some default value, for example.

I prefer everything indented, ie:

Code:
Section Title:
    Section body
    ...

Another Section:
    - Items
    ...

Ctrl+T does the Tabbing magic.

With the KeyPg* and CatPg* pages, let's use no boxes, complex formatting and such, or it will be pain to convert to other formats and to maintain the pages - say if the wiki script is changed later.. who knows.

Other than that, we have to create the CatPg* pages and put the KeyPg* links on them, plus fix the back link at each CatPg.

Each contributor could choose a category and start fixing/adding/changing the KeyPg* pages, it's up to you to decide.

Would be great to have to pages formatted and completed, so a CHM can be generated from them and included in the FBIDE, to add quick-help support.