Skip to content

Commit

Permalink
cleanup: Remove 'status_bar_' config prefixes
Browse files Browse the repository at this point in the history
As this project is now simply a status bar on its own, the
'status_bar_' prefix on all config options seemed superfluous :)
  • Loading branch information
cmacrae committed Apr 16, 2020
1 parent 9dc81e4 commit c982829
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 46 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@ All of the configuration options can be changed at runtime as well.

Example configuration:
```
spacebar -m config status_bar_text_font "Helvetica Neue:Bold:12.0"
spacebar -m config status_bar_icon_font "Font Awesome 5:Regular:12.0"
spacebar -m config status_bar_background_color 0xff202020
spacebar -m config status_bar_foreground_color 0xffa8a8a8
spacebar -m config status_bar_space_icon_strip I II III IV V VI VII VIII IX X
spacebar -m config status_bar_power_icon_strip  
spacebar -m config status_bar_space_icon
spacebar -m config status_bar_clock_icon
spacebar -m config text_font "Helvetica Neue:Bold:12.0"
spacebar -m config icon_font "Font Awesome 5:Regular:12.0"
spacebar -m config background_color 0xff202020
spacebar -m config foreground_color 0xffa8a8a8
spacebar -m config space_icon_strip I II III IV V VI VII VIII IX X
spacebar -m config power_icon_strip  
spacebar -m config space_icon
spacebar -m config clock_icon
```

- Sample configuration files can be found in the [↗ examples][spacebar-examples] directory. Refer to the [↗ documentation][spacebar-docs].
Expand Down
20 changes: 10 additions & 10 deletions doc/spacebar.1
Original file line number Diff line number Diff line change
Expand Up @@ -70,48 +70,48 @@ Get or set the value of <setting>.
Enable output of debug information to stdout.
.RE
.sp
\fBstatus_bar_text_font\fP [\fI<font_family>:<font_style>:<font_size>\fP]
\fBtext_font\fP [\fI<font_family>:<font_style>:<font_size>\fP]
.RS 4
Specify name, style and size of font to use for drawing text.
.br
Use \fIFont Book.app\fP to identify the correct name.
.RE
.sp
\fBstatus_bar_icon_font\fP [\fI<font_family>:<font_style>:<font_size>\fP]
\fBicon_font\fP [\fI<font_family>:<font_style>:<font_size>\fP]
.RS 4
Specify name, style and size of font to use for drawing icon symbols.
.br
Use \fIFont Book.app\fP to identify the correct name.
.RE
.sp
\fBstatus_bar_background_color\fP [\fI<COLOR>\fP]
\fBbackground_color\fP [\fI<COLOR>\fP]
.RS 4
Color to use for drawing status bar background.
.RE
.sp
\fBstatus_bar_foreground_color\fP [\fI<COLOR>\fP]
\fBforeground_color\fP [\fI<COLOR>\fP]
.RS 4
Color to use for drawing status bar elements.
.RE
.sp
\fBstatus_bar_space_icon_strip\fP [\fI<sym_1> <sym_2> <sym_n>\fP]
\fBspace_icon_strip\fP [\fI<sym_1> <sym_2> <sym_n>\fP]
.RS 4
Specify symbols separated by whitespace to be used for visualizing spaces.
.RE
.sp
\fBstatus_bar_power_icon_strip\fP [\fI<sym_battery> <sym_ac>\fP]
\fBpower_icon_strip\fP [\fI<sym_battery> <sym_ac>\fP]
.RS 4
Specify two symbols separated by whitespace.
.br
The first symbol represents battery power and the second symbol indicates AC.
.RE
.sp
\fBstatus_bar_space_icon\fP [\fI<sym>\fP]
\fBspace_icon\fP [\fI<sym>\fP]
.RS 4
Specify a general symbol to use for any given space that does not have a match in \fIstatus_bar_space_icon_strip\fP.
Specify a general symbol to use for any given space that does not have a match in \fIspace_icon_strip\fP.
.RE
.sp
\fBstatus_bar_clock_icon\fP [\fI<sym>\fP]
\fBclock_icon\fP [\fI<sym>\fP]
.RS 4
Specify a symbol to represent the current time.
.RE
Expand All @@ -120,4 +120,4 @@ Specify a symbol to represent the current time.
If \fBspacebar\fP can\(cqt handle a message, it will return a non\-zero exit code.
.SH "AUTHOR"
.sp
Doron Somech <somdoron at gmail.com>
Doron Somech <somdoron at gmail.com>
20 changes: 10 additions & 10 deletions doc/spacebar.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -60,34 +60,34 @@ Settings
*debug_output* ['<BOOL_SEL>']::
Enable output of debug information to stdout.

*status_bar_text_font* ['<font_family>:<font_style>:<font_size>']::
*text_font* ['<font_family>:<font_style>:<font_size>']::
Specify name, style and size of font to use for drawing text. +
Use 'Font Book.app' to identify the correct name.

*status_bar_icon_font* ['<font_family>:<font_style>:<font_size>']::
*icon_font* ['<font_family>:<font_style>:<font_size>']::
Specify name, style and size of font to use for drawing icon symbols. +
Use 'Font Book.app' to identify the correct name.

*status_bar_background_color* ['<COLOR>']::
*background_color* ['<COLOR>']::
Color to use for drawing status bar background.

*status_bar_foreground_color* ['<COLOR>']::
*foreground_color* ['<COLOR>']::
Color to use for drawing status bar elements.

*status_bar_space_icon_strip* ['<sym_1> <sym_2> <sym_n>']::
*space_icon_strip* ['<sym_1> <sym_2> <sym_n>']::
Specify symbols separated by whitespace to be used for visualizing spaces.

*status_bar_power_icon_strip* ['<sym_battery> <sym_ac>']::
*power_icon_strip* ['<sym_battery> <sym_ac>']::
Specify two symbols separated by whitespace. +
The first symbol represents battery power and the second symbol indicates AC.

*status_bar_space_icon* ['<sym>']::
Specify a general symbol to use for any given space that does not have a match in 'status_bar_space_icon_strip'.
*space_icon* ['<sym>']::
Specify a general symbol to use for any given space that does not have a match in 'space_icon_strip'.

*status_bar_clock_icon* ['<sym>']::
*clock_icon* ['<sym>']::
Specify a symbol to represent the current time.

*status_bar_clock_format* ['<sym>']::
*clock_format* ['<sym>']::
Specify a format for the current time, according to the strftime function.

Exit Codes
Expand Down
18 changes: 9 additions & 9 deletions examples/spacebarrc
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#!/usr/bin/env sh

spacebar -m config status_bar_text_font "Helvetica Neue:Bold:12.0"
spacebar -m config status_bar_icon_font "Font Awesome 5 Free:Regular:12.0"
spacebar -m config status_bar_background_color 0xff202020
spacebar -m config status_bar_foreground_color 0xffa8a8a8
spacebar -m config status_bar_space_icon_strip I II III IV V VI VII VIII IX X
spacebar -m config status_bar_power_icon_strip  
spacebar -m config status_bar_space_icon
spacebar -m config status_bar_clock_icon
spacebar -m config status_bar_clock_format "%d/%m/%y %R"
spacebar -m config text_font "Helvetica Neue:Bold:12.0"
spacebar -m config icon_font "Font Awesome 5 Free:Regular:12.0"
spacebar -m config background_color 0xff202020
spacebar -m config foreground_color 0xffa8a8a8
spacebar -m config space_icon_strip I II III IV V VI VII VIII IX X
spacebar -m config power_icon_strip  
spacebar -m config space_icon
spacebar -m config clock_icon
spacebar -m config clock_format "%d/%m/%y %R"

echo "spacebar configuration loaded.."
18 changes: 9 additions & 9 deletions src/message.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ extern bool g_verbose;

/* --------------------------------DOMAIN CONFIG-------------------------------- */
#define COMMAND_CONFIG_DEBUG_OUTPUT "debug_output"
#define COMMAND_CONFIG_BAR_TEXT_FONT "status_bar_text_font"
#define COMMAND_CONFIG_BAR_ICON_FONT "status_bar_icon_font"
#define COMMAND_CONFIG_BAR_BACKGROUND "status_bar_background_color"
#define COMMAND_CONFIG_BAR_FOREGROUND "status_bar_foreground_color"
#define COMMAND_CONFIG_BAR_SPACE_STRIP "status_bar_space_icon_strip"
#define COMMAND_CONFIG_BAR_POWER_STRIP "status_bar_power_icon_strip"
#define COMMAND_CONFIG_BAR_SPACE_ICON "status_bar_space_icon"
#define COMMAND_CONFIG_BAR_CLOCK_ICON "status_bar_clock_icon"
#define COMMAND_CONFIG_BAR_CLOCK_FORMAT "status_bar_clock_format"
#define COMMAND_CONFIG_BAR_TEXT_FONT "text_font"
#define COMMAND_CONFIG_BAR_ICON_FONT "icon_font"
#define COMMAND_CONFIG_BAR_BACKGROUND "background_color"
#define COMMAND_CONFIG_BAR_FOREGROUND "foreground_color"
#define COMMAND_CONFIG_BAR_SPACE_STRIP "space_icon_strip"
#define COMMAND_CONFIG_BAR_POWER_STRIP "power_icon_strip"
#define COMMAND_CONFIG_BAR_SPACE_ICON "space_icon"
#define COMMAND_CONFIG_BAR_CLOCK_ICON "clock_icon"
#define COMMAND_CONFIG_BAR_CLOCK_FORMAT "clock_format"

/* --------------------------------COMMON ARGUMENTS----------------------------- */
#define ARGUMENT_COMMON_VAL_ON "on"
Expand Down

0 comments on commit c982829

Please sign in to comment.