On Fri, Jan 15, 2010 at 11:22, Ziggy <[email protected]> wrote:
Hi Thomas,
Yes i did notice that it does put a box around it. It doesnt show the box properly while editing but it does once you save it.
That's perfectly normal. That's the goal of the WYSIWYG: show you the content as you would see it in view mode.
is it possible to the same without worrying about the language?
If you don't put the language, code macro will try to find it itself. But it's not easy so it's not always right (plus it's a little slower since it has to determine the language before highlight the code snippet).
I did try this
{{code}} Some clever code goes here {{/code}}
It does work but the font defaults to "Arial" but i think in most wiki the font defaults to courier.
Thanks
I tried this
On Fri, Jan 15, 2010 at 9:49 AM, Thomas Mortagne <[email protected]>wrote:
On Fri, Jan 15, 2010 at 10:00, Ziggy <[email protected]> wrote:
Oh and also, when i use the "code" macro, it doesnt actually draw a box around the code but it rather highlights the text which is not i want.
Thanks
On Fri, Jan 15, 2010 at 8:33 AM, Ziggy <[email protected]> wrote:
Hi Guys,
What is the wiki syntax for display code in a page. Here is an example of what i would like to do. Look at this page http://15black.bluedepot.com/styles/tiddlypedia.htm , Look at the TiddlyPediaPackage section half way through the page. The syntax to achieve that is as simple as typing this
{{{ HTML Structure var sidebar = document.getElementbyId('sidebar') }}}
I tried to do the same for xwiki pages but it dont work. I think it is possible to do it using the "code" macro but this only works when you use the WYSIWYG editor. It doesnt work in WIKI edit mode. Is there a simple syntax that i can use to achieve this?
Everything you can do in the WYSIWYG also works in wiki syntax (WYSIWYG only generate wiki syntax at the end). When you don't know how to do something WYSIWYG did, save an edit the page in wiki mode.
And yes code macri is working well in wiki model also, for example:
{{code language=html}} <html> <head>Cool!</head> </html> {{/code}}
and it does print a box around unless you have a special (wrong) skin. See http://tuska.myxwiki.org/xwiki/bin/view/Test/Code
Thanks
_______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
-- Thomas Mortagne _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
-- Thomas Mortagne