mirror of
https://github.com/davatorium/rofi.git
synced 2024-10-27 05:23:18 -04:00
[DOC] Update rofi-theme(5) for github highlighting
This commit is contained in:
parent
a230f193fb
commit
6f28a171ac
1 changed files with 28 additions and 28 deletions
|
@ -29,14 +29,14 @@ Comments can be nested and the C comments can be inline.
|
||||||
|
|
||||||
The following is valid:
|
The following is valid:
|
||||||
|
|
||||||
```
|
```css
|
||||||
// Magic comment.
|
// Magic comment.
|
||||||
property: /* comment */ value;
|
property: /* comment */ value;
|
||||||
```
|
```
|
||||||
|
|
||||||
However, this is not:
|
However, this is not:
|
||||||
|
|
||||||
```
|
```css
|
||||||
prop/*comment*/erty: value;
|
prop/*comment*/erty: value;
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -46,13 +46,13 @@ White space and newlines, like comments, are ignored by the parser.
|
||||||
|
|
||||||
This:
|
This:
|
||||||
|
|
||||||
```
|
```css
|
||||||
property: name;
|
property: name;
|
||||||
```
|
```
|
||||||
|
|
||||||
Is identical to:
|
Is identical to:
|
||||||
|
|
||||||
```
|
```css
|
||||||
property :
|
property :
|
||||||
name
|
name
|
||||||
|
|
||||||
|
@ -72,7 +72,7 @@ Sub-section names begin with a hash symbol `#`.
|
||||||
It is advised to define the *global properties section* on top of the file to
|
It is advised to define the *global properties section* on top of the file to
|
||||||
make inheritance of properties clearer.
|
make inheritance of properties clearer.
|
||||||
|
|
||||||
```
|
```css
|
||||||
/* Global properties section */
|
/* Global properties section */
|
||||||
* {
|
* {
|
||||||
// list of properties
|
// list of properties
|
||||||
|
@ -112,7 +112,7 @@ Multiple elements can be specified by a `,`.
|
||||||
|
|
||||||
This is a valid element name:
|
This is a valid element name:
|
||||||
|
|
||||||
```
|
```css
|
||||||
element normal.normal {
|
element normal.normal {
|
||||||
background-color: blue;
|
background-color: blue;
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,7 @@ button {
|
||||||
|
|
||||||
And is identical to:
|
And is identical to:
|
||||||
|
|
||||||
```
|
```css
|
||||||
element normal normal, button {
|
element normal normal, button {
|
||||||
background-color: blue;
|
background-color: blue;
|
||||||
}
|
}
|
||||||
|
@ -133,7 +133,7 @@ Each section inherits the global properties. Properties can be explicitly inheri
|
||||||
`inherit` keyword.
|
`inherit` keyword.
|
||||||
In the following example:
|
In the following example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
window {
|
window {
|
||||||
a: 1;
|
a: 1;
|
||||||
b: 2;
|
b: 2;
|
||||||
|
@ -148,7 +148,7 @@ mainbox {
|
||||||
|
|
||||||
The element `mainbox` will have the following set of properties (if `mainbox` is a child of `window`):
|
The element `mainbox` will have the following set of properties (if `mainbox` is a child of `window`):
|
||||||
|
|
||||||
```
|
```css
|
||||||
a: 1;
|
a: 1;
|
||||||
b: 4;
|
b: 4;
|
||||||
c: 8;
|
c: 8;
|
||||||
|
@ -162,7 +162,7 @@ the last encountered property is used.
|
||||||
|
|
||||||
The properties in a section consist of:
|
The properties in a section consist of:
|
||||||
|
|
||||||
```
|
```css
|
||||||
{identifier}: {value};
|
{identifier}: {value};
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -205,7 +205,7 @@ A string is always surrounded by double quotes (`"`). Between the quotes there c
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
font: "Awasome 12";
|
font: "Awasome 12";
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -219,7 +219,7 @@ An integer may contain any number.
|
||||||
|
|
||||||
For examples:
|
For examples:
|
||||||
|
|
||||||
```
|
```css
|
||||||
lines: 12;
|
lines: 12;
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -231,7 +231,7 @@ A real is an integer with an optional fraction.
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
real: 3.4;
|
real: 3.4;
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -246,7 +246,7 @@ Boolean value is either `true` or `false`. This is case-sensitive.
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
dynamic: false;
|
dynamic: false;
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -309,14 +309,14 @@ The different values are:
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
background-color: #FF0000;
|
background-color: #FF0000;
|
||||||
border-color: rgba(0,0,1, 0.5);
|
border-color: rgba(0,0,1, 0.5);
|
||||||
text-color: SeaGreen;
|
text-color: SeaGreen;
|
||||||
```
|
```
|
||||||
or
|
or
|
||||||
|
|
||||||
```
|
```css
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
text-color: Black;
|
text-color: Black;
|
||||||
```
|
```
|
||||||
|
@ -362,7 +362,7 @@ Distances used in the horizontal direction use the monitor width. Distances in
|
||||||
the vertical direction use the monitor height.
|
the vertical direction use the monitor height.
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
padding: 10%;
|
padding: 10%;
|
||||||
```
|
```
|
||||||
On a full-HD (1920x1080) monitor, it defines a padding of 192 pixels on the left
|
On a full-HD (1920x1080) monitor, it defines a padding of 192 pixels on the left
|
||||||
|
@ -372,7 +372,7 @@ and right side and 108 pixels on the top and bottom.
|
||||||
|
|
||||||
Rofi supports some maths in calculating sizes. For this it uses the CSS syntax:
|
Rofi supports some maths in calculating sizes. For this it uses the CSS syntax:
|
||||||
|
|
||||||
```
|
```css
|
||||||
width: calc( 100% - 37px );
|
width: calc( 100% - 37px );
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -454,13 +454,13 @@ A reference can point to another reference. Currently, the maximum number of red
|
||||||
A property always refers to another property. It cannot be used for a subpart of the property.
|
A property always refers to another property. It cannot be used for a subpart of the property.
|
||||||
For example, this is not valid:
|
For example, this is not valid:
|
||||||
|
|
||||||
```
|
```css
|
||||||
highlight: bold @pink;
|
highlight: bold @pink;
|
||||||
```
|
```
|
||||||
|
|
||||||
But this is:
|
But this is:
|
||||||
|
|
||||||
```
|
```css
|
||||||
* {
|
* {
|
||||||
myhigh: bold #FAA;
|
myhigh: bold #FAA;
|
||||||
}
|
}
|
||||||
|
@ -496,7 +496,7 @@ The `keyword` in the list refers to an widget name.
|
||||||
This will parse the environment variable as the property value. (that then can be any of the above types).
|
This will parse the environment variable as the property value. (that then can be any of the above types).
|
||||||
The environment variable should be an alphanumeric string without white-space.
|
The environment variable should be an alphanumeric string without white-space.
|
||||||
|
|
||||||
```
|
```css
|
||||||
* {
|
* {
|
||||||
background-color: ${BG};
|
background-color: ${BG};
|
||||||
}
|
}
|
||||||
|
@ -508,7 +508,7 @@ The environment variable should be an alphanumeric string without white-space.
|
||||||
|
|
||||||
Inherits the property from its parent widget.
|
Inherits the property from its parent widget.
|
||||||
|
|
||||||
```
|
```css
|
||||||
mainbox {
|
mainbox {
|
||||||
border-color: inherit;
|
border-color: inherit;
|
||||||
}
|
}
|
||||||
|
@ -522,7 +522,7 @@ Some widgets have an extra state.
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
element selected {
|
element selected {
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@ -531,7 +531,7 @@ Here `element selected` is the name of the widget, `selected` is the state of th
|
||||||
|
|
||||||
The difference between dots and spaces is purely cosmetic. These are all the same:
|
The difference between dots and spaces is purely cosmetic. These are all the same:
|
||||||
|
|
||||||
```
|
```css
|
||||||
element .selected {
|
element .selected {
|
||||||
|
|
||||||
element.selected {
|
element.selected {
|
||||||
|
@ -605,7 +605,7 @@ These can be mixed.
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
```
|
```css
|
||||||
nametotextbox selected.active {
|
nametotextbox selected.active {
|
||||||
background-color: #003642;
|
background-color: #003642;
|
||||||
text-color: #008ed4;
|
text-color: #008ed4;
|
||||||
|
@ -798,9 +798,9 @@ The current layout of **rofi** is structured as follows:
|
||||||
|
|
||||||
|
|
||||||
```
|
```
|
||||||
> ci is the case-indicator
|
> * ci is the case-indicator
|
||||||
> fr is the num-filtered-rows
|
> * fr is the num-filtered-rows
|
||||||
> ns is the num-rows
|
> * ns is the num-rows
|
||||||
|
|
||||||
### Error message structure
|
### Error message structure
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue