Roland
July 1, 2025, 10:46am
1
Hi.
First of all: I love the new boxstyles. Thanks for implementing them.
Is there a possibility to create an own boxstyle “mybox”? And can you please guide me a little through the menues?
“Create your own box in the box macro” won´t help me finding a solution.
Thanks in advance.
Roland
I found a way to change existing boxes:
How to customize Error/Warning/Success/Info Macro? - Help / Discuss - XWiki Forum
But how do I add a new custom box, which is shown in the ck-editor?
The things that are shown in the CKEditor are wiki macros. I believe it should add it there as soon as you make your new macro available on your wiki.
You can either write it
For either implementation, I recommend inspiring yourself from the abstract message macro and the few existing children of this abstract class.
Good luck with writing your customization!
Lucas C.
2 Likes
Roland
February 27, 2026, 9:07am
4
Hi.
Maybe a stupid question,… where are the default-macros stored? In the main wiki, in sub-wikis, in the theme?
Thx in advance.
Roland
A bit everywhere, depending on the macro ^^’
For the box macro, it’s defined at https://github.com/xwiki/xwiki-rendering/blob/579b7fcde2c77499e87611c38f2fec1c6eb49ef6/xwiki-rendering-macros/xwiki-rendering-macro-box/src/main/java/org/xwiki/rendering/internal/macro/box/DefaultBoxMacro.java which is stored in the xwiki-rendering-macro-box-X.X.X.jar.
The existing message macros are defined at xwiki-rendering/xwiki-rendering-macros/xwiki-rendering-macro-message/src/main/java/org/xwiki/rendering/internal/macro/message/InfoMessageMacro.java at 07aca1b9a5129a6bf44599821bd8c6d390f5e32d · xwiki/xwiki-rendering · GitHub and stored in the xwiki-rendering-macro-message-X.X.X.jar .
Some default macros are defined in their own XWiki page, like the children macro.
You can get a full list of macros at XWikiSyntaxMacrosList which is linked from the macro page in the help application (pretty difficult to find overwise IMO).
1 Like