version=pmwiki-2.0.beta21
newline=В
text=WikiStyles allow an author to modify the color and other attributes of text that follow.  A style specification such as @@[=%red%=]@@ will cause the following text to be displayed as red until the end of the line or the next pair @@[=%%=]@@ of percent signs.  For example:ВВ   [=%red%=] This text is red and [=%blue%=] this text is blue [=%%=] but В   this text is normal.ВВgivesВВ->%red% This text is red and %blue% this text is blue %% but this text is normal.ВВThe set of [[predefined wiki styles]] is customizable by the WikiAdministrator.  Most PmWiki systems define [=%newwin%=] to cause links to open in a new window (%newwin%[[WikiStyles |example]]), and standard text colors such as [=%black%, %white%, %red%, %green%, %blue%, etc.=]ВВ!!Creating new stylesВВPlacing @@color@@, @@bgcolor@@, or @@target@@ specifications inside of a pair of percent signs will change the style of the following text to use those colors up to the end of a line or until the next pair of percent-signs.  For example:ВВ    [=%color=red% This text is red and %color=blue% this text В    is blue %% but this text is normal. =]ВВrenders asВВ->%color=red% This text is red and %color=blue% this text is blue %% but this text is normal.ВВIf one wants the formatting to continue past the end of the line, there are a couple options one can use (found [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/7415|here]]).ВВFor example, using [=%block color=red%=] will continue the formatting until it gets to to the end of the current block/paragraph.  For example:ВВ(:markup:)[=ВThis is some text %block color=red% thatВis being colored red by the wikistyle in the line.В=]ВВThe other options (according to the [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/7415 | e-mail]]) are:\\В[=%item color=red%=]\\В[=%list color=red%=]\\В[=%block color=red%=]ВВ!!!!A brief explanation of the difference between item, list, and blockВ Apply=block applies to any sort of block markup, such asВparagraphs, lists, indents, and list items.  Apply=list applies to anВentire list -- i.e., anything that generates a <dl>, <ol>, or <ul> tag.ВApply=item applies only to an individual list item (<li>, <dd>, <dt>).ВВSo given the markupВВ(:markup:)[=В   * %apply=XXX border='1px solid black'% FirstВ   * secondВ   * third =]ВВif XXX is 'item' (as in 'apply=item'), then only the first bullet itemВwill have a box around it.  If XXX is 'list', then the entire bulletВlist will be placed in a box.  And if XXX is 'block', then the bulletВlist will be placed in a box, as well as the first list item (becauseВ'block' covers both).ВВOne can also change the background color using the @@bgcolor@@ attribute:ВВ    [=%color=black bgcolor=green% This text is black on green В    %color=green bgcolor=black% and this is green on black.%% =]ВВ%color=black bgcolor=green% This text is black on green %color=green bgcolor=black% and this is green on black.%% ВВOne can specify that links should open in a new window via the @@target@@ attribute:ВВ    [=%target=_blank% Any links on this line like http://www.pmichaud.com В    will open in a new window. =]ВВwhich givesВВ->%target=_blank% Any links on this line like http://www.pmichaud.com will open in a new window.ВВFinally, WikiStyles can control the width and height of ImagesInWikiPages, thus the markupВВ    [=%height=50% http://www.example.com/some.gif=]ВВwill display some.gif scaled to a height of 50 pixels.ВВВ!!Style definitionsВ%define=hotpink color=#ff69b4%В%define=reverse color=white bgcolor=black%ВВWiki authors can also make their own [[WikiStyle(s)]] definitions within a document using the @@define@@ attribute.  For example, the statementВВ    [=%define=hotpink color=#ff69b4%=]ВВwill cause the markup @@[=%hotpink%=]@@ to be a shortcut for @@[=%color=#ff69b4%=]@@ (%hotpink%like this%%).  One can specify multiple items in a definition, as inВВ    [=%define=reverse color=white bgcolor=black%=]ВВwhich allows @@[=%reverse%=]@@ to cause %reverse%reverse video%%, and @@[=%reverse hotpink%=]@@ to be the %reverse hotpink%combination of both shortcuts%%.  ВВIt's often a good idea to put common style definitions into GroupHeaders so that they can be shared among multiple pages in a group.  Or, the WikiAdministrator can predefine styles as a [[LocalCustomization(s)]] -- see WikiStylesAdmin.ВВ!!Predefined stylesВВSee [[predefined wiki styles]] for a description of the WikiStyles that are defined in a standard installation of PmWiki. That page also describes how an administrator can predefine additional WikiStyles.ВВ!!ColorsВFor some examples of colors, see WikiStyleColorsВВ%trail% <<|PmWiki.DocumentationIndex|>>ВВ
time=1108940750
host=70.23.39.251
agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0
rev=43
post= Save
author=menachem
name=PmWiki.WikiStyles
targets=PmWiki.WikiStyles,PmWiki.PredefinedWikiStyles,PmWiki.WikiAdministrator,PmWiki.PmWiki,PmWiki.ImagesInWikiPages,PmWiki.LocalCustomizations,PmWiki.GroupHeaders,PmWiki.WikiStylesAdmin,PmWiki.WikiStyleColors,PmWiki.Uploads,PmWiki.WikiStyleExamples,PmWiki.DocumentationIndex