-
Notifications
You must be signed in to change notification settings - Fork 1
@example tag ignores <caption> and line-breaks #76
Comments
Hello, thanks for reporting this issue. But, currently is posible to do multiline examples like this: /**
* @function bb_create
*
* @description
* Creates a basic button (BB) in the specified position
* with the text "text" and with the sprite specified as background.
*
* @example
*
* // Create Event:
* my_button = bb_create(x, y, "Press Me", 20, font0, spr_button, true);
*
* //Step event:
* bb_step(my_button);
* if (bb_on_pressed(my_button)) {
* show_message_async("The button has beeen pressed");
* }
*
* // Draw Event:
* bb_draw(my_button);
*
*
*/ This should be rendered correcly. Also, you can have more than one |
That would be fantastic. I've been working around it by including the styled "pre" within the code but it's super tacky looking inside the editor. As for the multi-line, I played with it a bit more and found out what I was doing wrong; something stupid on my end. If you don't have the code flush with the @example tag then the following line won't insert a break thus making things show up on one line. This issue is what I was referring to but it ended up being my formatting rather than an issue with the engine. I have a habit of indenting past tags but that messes up @example. |
Oh. I see. Can you paste an example of the documentation code that messed
up the system? I want to see if is something that I can adapt to work with.
El lun., 7 de oct. de 2019 9:52 p. m., Reuben Shea <notifications@github.com>
escribió:
… That would be fantastic. I've been working around it by including the
styled
within the code but it's super tacky looking inside the editor.
As for the multi-line, I played with it a bit more and found out what I was doing wrong; something stupid on my end. If you don't have the code flush with the @example tag then the following line won't insert a break thus making things show up on one line.
This issue is what I was referring to but it ended up being my formatting rather than an issue with the engine. I have a habit of indenting past tags but that messes up @example.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#76?email_source=notifications&email_token=AB46I7YUXYT44DO6A5KEEQDQNPKWJA5CNFSM4I57DQDKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEASIXXI#issuecomment-539266013>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AB46I72R4WWKJ4QZT2YBQ6TQNPKWJANCNFSM4I57DQDA>
.
|
Man, now I feel like I've been wasting your time. -.-" /** @desc This is some example function. @example some_function(); show_message("Some message"); // This line should be fine, though **/ But I'm having a hard time getting it to crop up now. I took notes on this a bit back and didn't report it until recently so maybe it was some of my old CSS messing things up. I notice that if I replace "some_function()" with something like "var = instance_create(0, 0, instance)" then it goes away. |
Not sure if it's a bug or just not implemented yet.
As stated, @example seems to ignore and there is no way to do line breaks (even w/ HTML). This makes @example only good for simple single-line examples.
The text was updated successfully, but these errors were encountered: