Advanced Formatting Techniques
Asked by Phillip Ponzer [Cprime]:

<http://confluence.atlassian.com/display/CONF40/Confluence+Wiki+Markup>

This Confluence Wiki Markup page details a lot of what the WYSIWYG editor can do, but some abilities seem missing. For instance, left/center/right align and font color don't have formatting shortcuts similar to \* for bold and _ for italics.

Looking around some more revealed that this used to be supported (amongst others):

* [https://answers.atlassian.com/questions/2060/confluence-4-0-formatting-as-code-no-longer-in-dropdown](/questions/2060/confluence-4-0-formatting-as-code-no-longer-in-dropdown)
* [https://answers.atlassian.com/questions/4167/the-style-macro-doesn-t-seem-to-work](/questions/4167/the-style-macro-doesn-t-seem-to-work)

Are there any other advanced formatting techniques out there that aren't well-known? For instance, I'd like to know how to apply a smaller font size to some text, or even a different color (without using the buttons in the WYSIWYG editor), perhaps I'd like to specify something other than predefined "red", "blue", or "green" colors, maybe I'd like to change the alignment of the text.

Any thoughts?


Answers:
author: Andrew Frayling
body: Hi Phillip,

There's nothing in the editor at the moment that lets you change font size, alignment, etc. using shortcuts rather than the editor menus, but Atlassian are tracking all feedback on the editor at <http://confluence.atlassian.com/display/DOC/Confluence+4.0+Editor+-+Customer+Feedback> so if these are features that you'd like to see you can leave a comment on the page.

In the meantime you may find these documents useful:

[Quick Reference Guide for the Confluence Editor](http://confluence.atlassian.com/display/DOC/Quick+Reference+Guide+for+the+Confluence+Editor)

[Keyboard Shortcuts](http://confluence.atlassian.com/display/DOC/Keyboard+Shortcuts)

[Using Autocomplete](http://confluence.atlassian.com/display/DOC/Using+Autocomplete)

Also, looking at the comment you left on [https://answers.atlassian.com/questions/4167/the-style-macro-doesn-t-seem-to-work](/questions/4167/the-style-macro-doesn-t-seem-to-work) you can enter these sort of CSS properties without needing the {style} macro by enabling the {html} macro that ships with Confluence, but is disabled by default. To enable:

1. Log in to Confluence as a Confluence Administrator  
2. Select Browse -\> Confluence Admin -\> Plugins  
3. Select Show System Plugins  
4. Search for HTML  
5. Click Manage plugin modules on the Confluence HTML Macro  
6. Enable the HTML macro

In the editor you can now use raw HTML by using the {html} macro, e.g.

```
{html}<p style="text-align:center">hello</p>{html}
```

Hope that helps?

Andrew.

comments: author: Phillip Ponzer [Cprime]
body: Perhaps I should've been more indicative in my post. I'm currently converting our MediaWiki into Confluence using the UWC and whenever I use the {html} macro (as a replacement for a few regex's in the converter.mediawiki.properties file), it fails to upload (perhaps convert?) the page altogether. Maybe I should tag UWC in this question... :)


author: Phillip Ponzer [Cprime]
body: For instance, using this in the converter.mediawiki.properties file doesn't work (as in, it bails the conversion when it tries to do this):

```
Mediawiki.1420.optionalunnestedhtml-big.java-regex=<big>(.*?)<\/big>{replace-with}{html}<big>$1<\/big>{html}
```


author: Andrew Frayling
body: Hi Phillip,

It might be worth starting a new question specifically about UWC for the issues you're getting with your conversion. I'm not a UWC expert, but I know the UWC authors are active on Atlassian Answers and are very helpful with questions about UWC.

Andrew.


author: Phillip Ponzer [Cprime]
body: In reply to my comment about the "big" HTML tags not converting properly, it was because I didn't have the deprecated HTML macro enabled.


Tags: format

markup

universal-wiki-converter

wysiwyg