On source conventions and documentation [Release!]

A General Discussion forum for TI calculators

Moderator: MaxCoderz Staff

User avatar
qarnos
Maxcoderz Staff
Posts: 227
Joined: Thu 01 Dec, 2005 9:04 am
Location: Melbourne, Australia

Post by qarnos »

Another request :D

Would it be possible to allow custom fields? For example. instead of just the preset fields "Pre", "Post", "Warning", etc, could it be possible for a user to include a custom field in the source and use CSS for layout?

A field could be identified as any string at the start of a double-semicolon line followed by a colon. For instance:

Code: Select all

;; Pre:
;;  This is a normal field
;;
;; Destroyed:
;;  This is a custom field
Yes, I know I should just let go of the whole "destroyed" thing, but it feels weird to be listing destroyed registers as output. I want a destroyed field! ;)

Allowing custom fields would give much more flexibility outside of the Vera project. And since I'm not the guy who's writing the program and have no idea of what is involved, I feel it's my right to demand all kinds of crazy features. :D


EDIT: Also it seems that the < and > are not properly escaped. I use < in one of my comments and the xml parser chokes on it - it thinks it's a tag.
"I don't know why a refrigerator is now involved, but put that aside for now". - Jim e on unitedti.org

avatar courtesy of driesguldolf.
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

qarnos wrote:And since I'm not the guy who's writing the program and have no idea of what is involved, I feel it's my right to demand all kinds of crazy features. :D
Right you are, of course... I'll get to it asap ;)

To be honest, I've been thinking about something similar. Following the XSLT tradition, I should write some kind of XML definition that defines how the assembly comments should get parsed into XML... But writing the parser for that would be agony. Especially seeing that I've written this thing in C, which isn't really the simplest language for these kinds of things...
EDIT: Also it seems that the < and > are not properly escaped. I use < in one of my comments and the xml parser chokes on it - it thinks it's a tag.
Ah, another bug :) Hooray ;) There should be a few more characters I forgot/don't escape.

If you'd like; the source for this thing is on the Vera SVN, feel free to fix/expand whatever you like.
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
User avatar
qarnos
Maxcoderz Staff
Posts: 227
Joined: Thu 01 Dec, 2005 9:04 am
Location: Melbourne, Australia

Post by qarnos »

If you'd like; the source for this thing is on the Vera SVN, feel free to fix/expand whatever you like.
Cool - I didn't realize that. I'll take a look at it.
"I don't know why a refrigerator is now involved, but put that aside for now". - Jim e on unitedti.org

avatar courtesy of driesguldolf.
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

The parser is utter crap from a C novice (I'm still learning, sorry :mrgreen:), but the scanner is somewhat alright, and it works quite alright for our Vera source ;) Anyway, suggestions for improvements are of course welcome, as well as contributions...
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
Post Reply