styling.xml

styling
Styling the GUI and web pages

Contents

Pentadactyl allows you to apply custom CSS styling to the web pages you view as well as to the browser itself. Although it is possible to style any user interface element via the :style command, most Pentadactyl elements can be styled more easily by means of the more specialized :highlight command.

E185:colo:colorscheme
:colo[rscheme] {name}

Load a color scheme. {name} is found by searching the 'runtimepath' for the first file matching colors/{name}.penta. The special scheme default can be used to reload the default highlight settings.

The ColorScheme autocommand is triggered after the color scheme has been sourced.

:hi:highlight
:hi[ghlight][!] {group}[selector]
:hi[ghlight][!] [-append] [-link={group},…] {group}[selector] [css]

Highlight {group} with [css]. [css] is one or more semicolon-separated CSS declarations (E.g. color: blue; background-color: red). [selector], if provided, may be any valid CSS selector (such as :hover or [href]), and will restrict the highlighting to matching elements.

If -link (short name -l) is supplied, the value of each of the listed groups is prepended to the style of this group.

Valid groups include:

Addon
An add-on in the :addons manager
AddonBar
AddonButton
AddonButtons
AddonCell
A cell in tell :addons manager
AddonDescription
AddonHead
A heading in the :addons manager
AddonName
AddonStatus
AddonVersion
Addons
The :addons manager
AppmenuButton
The app-menu button
Bell
Pentadactyl's visual bell
Boolean
JavaScript booleans
Button
A button widget
Buttons
A group of buttons
CmdCmdLine
CmdErrorMsg
CmdInfoMsg
CmdInput
CmdLine
The command line
CmdModeMsg
CmdMoreMsg
CmdNormal
CmdOutput
The output of commands executed by :run
CmdPrompt
CmdQuestion
CmdWarningMsg
Comment
JavaScriptor CSS comments
CompDesc
The description column of the completion list
CompGroup
Item group in completion output
CompIcon
The favicon of a completion row
CompIcon>img
CompItem
A single row of output in the completion list
CompItem[selected]
A selected row of completion list
CompLess::after
The character of indicator shown when completions may be scrolled up
CompLess
The indicator shown when completions may be scrolled up
CompMore::after
The character of indicator shown when completions may be scrolled down
CompMore
The indicator shown when completions may be scrolled down
CompMsg
The message which may appear at the top of a group of completion results
CompResult
The result column of the completion list
CompTitle
Completion row titles
CompTitleSep
The element which separates the completion title from its results
Dense
Arbitrary elements which should be packed densely together
Disabled
Disabled item indicator text
Download[active]
A currently active download
Download
A download in the :downloads manager
DownloadButtons
A button group in the :downloads manager
DownloadCell
A table cell in the :downloads manager
DownloadHead
A heading in the :downloads manager
DownloadPercent
The percentage column for a download
DownloadProgress
The progress column for a download
DownloadProgressHave
The completed portion of the progress column
DownloadProgressTotal
The remaining portion of the progress column
DownloadSource
The download source column for a download
DownloadState
The download state column for a download
DownloadTime
The time remaining column for a download
DownloadTitle
The title column for a download
Downloads
The :downloads manager
EditorBlink1
Text fields briefly after successfully running the external editor, alternated with EditorBlink2
EditorBlink2
Text fields briefly after successfully running the external editor, alternated with EditorBlink1
EditorEditing
Text fields for which an external editor is open
EditorError
Text fields briefly after an error has occurred running the external editor
Enabled
Enabled item indicator text
ErrorMsg
Error messages
Filter
The matching text in a completion list
FontCode
The font used for code listings
FontFixed
The font used for fixed-width text
FontProportional
The font used for proportionally spaced text
Find
Text find highlighting. Only background and foreground colors apply.
FrameIndicator
The styling applied to briefly indicate the active frame
Function
JavaScript functions
Help
A help page
HelpArg
A required command argument indicator
HelpBody
The body of a help page
HelpBorder
The styling of bordered elements
HelpCode
Code listings
HelpDefault
The default value of a help item
HelpDescription
The description of a help item
HelpDescription[short]
HelpEm
Emphasized text
HelpEx
An Ex command
HelpExample
An example
HelpHead1
Any help heading
HelpHead2
A first-level help heading
HelpHead3
A second-level help heading
HelpHead4
A third-level help heading
HelpHead
A fourth-level help heading
HelpInclude
A help page included in the consolidated help listing
HelpInfo
Arbitrary information about a help item
HelpInfoLabel
The label for a HelpInfo item
HelpInfoValue
The details for a HelpInfo item
HelpItem
A help item
HelpKey
A keyboard key specification
HelpKeyword
A keyword
HelpLink
A hyperlink
HelpLink[rel=external]
A hyperlink to an external resource
HelpList
An unordered list
HelpListItem
A list item, ordered or unordered
HelpNews
A news item
HelpNewsNew
A new news item
HelpNewsOld
An old news item
HelpNewsTag
The version tag for a news item
HelpNote
The indicator for a note
HelpOpt
An option name
HelpOptInfo
Information about the type and default values for an option entry
HelpOptionalArg
An optional command argument indicator
HelpOrderedList1
A first-level ordered list
HelpOrderedList2
A second-level ordered list
HelpOrderedList3
A third-level ordered list
HelpOrderedList4
A fourth-level ordered list
HelpOrderedList
Any ordered list
HelpParagraph
An ordinary paragraph
HelpSpec
The specification for a help entry
HelpString
A quoted string
HelpTOC
The Table of Contents for a help page
HelpTOC>ol
HelpTT
Teletype text
HelpTab
HelpTabColumn
HelpTabDescription
The description column of description tables
HelpTabRow
Entire rows in description tables
HelpTabTitle
The title column of description tables
HelpTag
A help tag
HelpTags
A group of help tags
HelpTopic
A link to a help topic
HelpType
An option type
HelpWarning
The indicator for a warning
HelpXML
Highlighted XML
HelpXMLAttribute
HelpXMLBlock
HelpXMLComment
HelpXMLNamespace
HelpXMLProcessing
HelpXMLString
HelpXMLTagEnd
HelpXMLTagStart
HelpXMLText
Hint
HintActive
The hint element of link which will be followed by <CR>
HintElem
The hintable element
HintImage
The indicator which floats above hinted images
Hint[active]
Indicator
The # and % in the :buffers list
InfoMsg
Information messages
InlineHelpLink
A help link shown in the command line or multi-line output area
Key
Keywords
Keyword
A bookmark keyword for a URL
LineNr
The line number of an error
Link
A link with additional information shown on hover
LinkInfo
Information shown when hovering over a link
Message
Message
A message as displayed in :messages
ModeMsg
The mode indicator
MoreMsg
The indicator that there is more text to view
NonText
The ~ indicators which mark blank lines in the completion list
Normal
Normal text
Null
JavaScript null values
Number
JavaScript numbers
Object
JavaScript objects
Preview
The completion preview displayed in the command line
Question
A prompt for a decision
REPL-E
Evaled input in REPL mode
REPL-P
Evaled output in REPL mode
REPL-R
Prompts in REPL mode
REPL
Read-Eval-Print-Loop output
StatusInfoMsg
Information messages in the status line
StatusLine
The status bar
StatusLineBroken
The status bar for a broken web page
StatusLineExtended
The status bar for a secure web page with an Extended Validation (EV) certificate
StatusLineNormal
The status bar for an ordinary web page
StatusLineSecure
The status bar for a secure web page
StatusModeMsg
The mode indicator in the status line
StatusMoreMsg
StatusNormal
Normal text in the status line
StatusQuestion
A prompt for a decision in the status line
StatusWarningMsg
A warning message in the status line
String
String values
TabClose
The close button of a browser tab
TabIcon
The icon of a browser tab
TabIconNumber
The number of a browser tab, over its icon
TabNumber
The number of a browser tab, next to its icon
TabText
The text of a browser tab
Tag
A bookmark tag for a URL
Title
The title of a listing, including :pageinfo, :jumps
URL:hover
URL
A URL
URLExtra
Extra information about a URL
Usage
Output from the :*usage commands
UsageBody
The body of listings in output from the :*usage commands
UsageHead
Headings in output from the :*usage commands
UsageItem
Individual items in output from the :*usage commands
WarningMsg
A warning message

The help system also has a comprehensive set of styling groups which are not explained here, but many of which are described along with writing-docs.

Every invocation completely replaces the styling of any previous invocation, unless -append (short name -a) is provided, in which case {css} is appended to its current value. If {css} is not provided, any styles beginning with {group} are listed.

:highlight-clear
:hi[ghlight] clear [group]

Reset the highlighting for [group] to its default value. If [group] is not given, reset all highlighting groups.

:sty:style
:sty[le] [-name={name}] [-group={name}] [-agent] {filter} {css}
:sty[le] -name={name} -append {filter} {css}
:sty[le] [-name={name}] [-group={name}] [filter]

Add CSS styles to the browser or to web pages. {filter} is a comma-separated list of site-filters for which the style will apply. The ! character may not be used to invert the sense of the match. [css] is a full CSS rule set (e.g., body { color: blue; }).

The following options are available:

-append
If provided along with -name, {css} and {filter} are appended to its current value. (short name -a)
-agent
If provided, the style is installed as an Agent sheet, which applies to contents user interface widgets as well as normal elements. (short name -A)
-group={group}
The group to which to add this style. Please note that this grouping is for semantic and cleanup purposes only. No additional site filtering is applied.
-name={name}
If provided, any existing style with the same name is overridden, and the style may later be deleted using {name}. (short name -n)

If [css] isn't provided, matching styles are listed.

:dels:delstyle
:dels[tyle][!] [-name={name}] [-index={index}] [filter] [css]

Delete any matching styles. With [!], delete all styles. If [filter] is provided, only matching elements of the filter are disabled. For instance, when run with a filter mozilla.org, an existing style with a filter www.google.com,mozilla.org, will result in a style for www.google.com.

The available options are:

-name
The name provided to :style (short name -n)
-index
For unnamed styles, the index listed by :style (short name -i)
:styleenable:stylee
:styenable:stye
:styled[isable][!] [-name={name}] [-index={index}] [filter] [css]

Enable any matching styles. With [!], enable all styles. Arguments are the same as for :delstyle

:styledisable:styled
:stydisable:styd
:stylee[nable][!] [-name={name}] [-index={index}] [filter] [css]

Disable any matching styles. With [!], disable all styles. Arguments are the same as for :delstyle

:styletoggle:stylet
:stytoggle:styt
:stylet[oggle][!] [-name={name}] [-index={index}] [filter] [css]

Toggle any matching styles. With [!], toggle all styles. Arguments are the same as for :delstyle