For PangoMarkup it is pretty useless currently (segment_info does not contain
anything useful).
Note: this does its job by replacing default behavior.
Source of issue: previous default used either segment_info argument (containing
{"args": args, "environ": os.environ}) or default segment_info, shell renderer
merged default segment_info with .render() argument. Now segment_info is merged
by default and old behavior moved to vim renderer which is the only one that is
designed to use this.
Fixes#391
Also moves functions from tests.test_config_reload to tests.lib.config_mock
Using create_renderer for vim results in vim access from a separate thread.
cwd segment was not drawing inner separators because of new default for
multisegment functions. use_path_separator was added because current variant
looks bad for my taste.
If weather or system_load segments were moved to the left draw_soft_divider
variant resulted in incorrect renderring. Thus it was replaced by
draw_inner_divider.
Previous variant was bad because
1. draw_divider only applied to soft dividers. Hard dividers were always drawn
2. But there was a hack with width=auto segments: for this segments draw_divider
setting applied always.
Now there are no additional dependencies: draw_*_divider applies no matter what
other properties of the segment are.
Currently only:
- Test for not reloading configuration if run_once is not True
- Test for reloading main configuration and other configurations triggered by
changes in main configuration file
TODO: tests for all other configuration files reloading (colors, colorscheme,
theme).
Custom interval (zero) will be used in tests.
Fixes:
- wrong check for subscribers receiving all events
- missing prev_ext_config setting that meant theme and colorscheme always
reloaded if main configuration was reloaded