SDL icon indicating copy to clipboard operation
SDL copied to clipboard

wikiheaders: format parameters consistently

Open icculus opened this issue 1 year ago • 4 comments

We are planning on having the wiki bridge format parameters consistently. @icculus, do we already have a task for that?

Originally posted by @slouken in https://github.com/libsdl-org/SDL/issues/11020#issuecomment-2386125373

icculus avatar Oct 01 '24 16:10 icculus

Current plan:

  • When writing wiki pages: one parameter per-line.
  • When writing headers, put it all on one line. Partially this is to help others that might parse the headers.

icculus avatar Dec 04 '24 18:12 icculus

Ouch! This was not my expectation. As someone who spends more time in the headers to learn from than the wiki, this is gonna hurt readability a lot.

aganm avatar Dec 04 '24 21:12 aganm

We are not married to this plan. :)

icculus avatar Dec 04 '24 21:12 icculus

Maybe we'll wrap it at 80 columns and that'll actually not suck for both headers and wiki. I'll have to experiment.

icculus avatar Dec 04 '24 21:12 icculus

Turns out this is going to need some heavier work than expected; wikiheaders doesn't parse C well-enough to cleanly wordwrap it at the moment, plus there are other problems with how we keep track of where to insert/replace documentation text that will currently blow up if the other parts of the file might also grow/shrink.

It's not unsolvable, but I don't think this will happen for 3.2.0.

icculus avatar Jan 11 '25 05:01 icculus