Modify ↓
Opened 16 years ago
Closed 15 years ago
#6697 closed enhancement (fixed)
I would be nice to be able to set the title of the box ...
| Reported by: | anonymous | Owned by: | Alexander Slesarev |
|---|---|---|---|
| Priority: | normal | Component: | CodeExampleMacro |
| Severity: | normal | Keywords: | |
| Cc: | Trac Release: | 0.11 |
Description
In a page with a lot of CodeExamples, having the possibility to replace Example (or Correct example, ...) by your own text would be a must.
Attachments (1)
Change History (3)
comment:1 Changed 16 years ago by
Changed 15 years ago by
comment:2 Changed 15 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
Fixed in r9204
Sample usage (see the title parameter):
{{{
#!CodeExample
## type = good
## title = Fibonacci implementation in Haskell
#!haskell
fibs = 0 : 1 : zipWith (+) fibs (tail fibs)
}}}
It will be rendered as:
Note: See
TracTickets for help on using
tickets.




Seems like a reasonably useful enhancement. Now that the
SELECT_ALLis shown on the right side of the box, a user-specified title could be displayed such as EXAMPLE: My example, rather than just EXAMPLE: ... and so forth for the other macros. Or perhaps replace the EXAMPLE: text entirely with user-defined text.