Update changelog a bit.

This commit is contained in:
Dave Davenport 2020-07-05 11:41:04 +02:00
parent d6ac2f0f5b
commit fc0ea0b22e
2 changed files with 34 additions and 9 deletions

View File

@ -15,14 +15,24 @@ have been possible.
## Script mode
Rofi now communicates some information back to the script using environment variables.
The most important one, is `ROFI_RETV`, this is equal to the return value in dmenu mode.
It can have the following values:
* Support for invisible search text
* Support for passing extra information back on selection
* Support for custom keybindings
* Support for custom delimiter
* Support for dmenus no-custom option
* **0**: Initial call of script.
* **1**: Selected an entry.
* **2**: Selected a custom entry.
* **10-28**: Custom keybinding 1-19
To fully read up on all features of script mode, there is now a `rofi-script(5)` manpage.
Some of the new features are:
* Search invisible text
* Pass extra information back on selection
* Support for a custom delimiter
* Support for dmenus no-custom option
## Theme
@ -32,12 +42,24 @@ There have been a set of tweaks to the theme format, making it more flexible and
### Listview flexibility
Instead of the listview having a hacked textbox as elements. It now re-uses existing widgets like box, icon and textbox.
This way you can re-structure how it looks. For example put the icon above the text.
This is one of the biggest change, instead of the listview having a hacked
textbox as elements. It now re-uses existing widgets like box, icon and
textbox. This way you can re-structure how it looks. For example put the icon
above the text.
![Icons](./icons.png)
With theme:
```css
element {
orientation: vertical;
}
```
This will make the box `element` put `element-icon` and `element-text` in a vertical list.
### Calculation support in theme format.
@ -50,6 +72,9 @@ window {
}
```
It supports: `-`, `+`, `/`, `*` and `%` operators and they should be surrounded by whitespace.
### Initial media support
This is a very initial implementation of CSS like `@media` support. This allows you to modify the theme

View File

@ -328,7 +328,7 @@ static void barview_draw ( widget *wid, cairo_t *draw )
if ( lv->barview.direction == LEFT_TO_RIGHT ) {
for ( unsigned int i = 0; i < max && width > 0; i++ ) {
update_element ( lv, i, i + offset, TRUE );
int twidth = widget_get_desired_width ( lv->boxes[i].box );//textbox_get_desired_width ( WIDGET ( lv->boxes[i].textbox ) );
int twidth = widget_get_desired_width ( WIDGET ( lv->boxes[i].box ) );
if ( twidth >= width ) {
if ( !first ) {
break;
@ -348,7 +348,7 @@ static void barview_draw ( widget *wid, cairo_t *draw )
else {
for ( unsigned int i = 0; i < lv->cur_elements && width > 0 && i <= offset; i++ ) {
update_element ( lv, i, offset - i, TRUE );
int twidth = widget_get_desired_width ( lv->boxes[i].box );// int twidth = textbox_get_desired_width ( WIDGET ( lv->boxes[i].textbox ) );
int twidth = widget_get_desired_width ( WIDGET ( lv->boxes[i].box ) );
if ( twidth >= width ) {
if ( !first ) {
break;