Closed travka closed 10 years ago
take a look on mpd backend for the music widget: https://github.com/actionless/awesome_config/tree/devel/widgets/music/backends/mpd.lua , u can add a backend for vk.com and when select it here: https://github.com/actionless/awesome_config/blob/devel/config/toolbar.lua#L25
so u can preformat one of the values in the vk.com backend code (strings will be shortened both for panel and notifications):
-- == 4
> print(string.format('%-4.4s', 'very_long_string'))
very
> print(string.format('%-4.4s', 've'))
ve
> print(string.format('%4.4s', 've'))
ve
-- <=4
> print(string.format('%.4s', 'very_long_string'))
very
> print(string.format('%.4s', 've'))
ve
or directly in the widget code (strings will be shortened only on panel, but will be visible fully in notifications): https://github.com/actionless/awesome_config/blob/devel/widgets/music/widget.lua#L191
fixed by the commit above
I'm Trying to add vkpd functional to this config. I have a problem right now. Mpd didn't get right tags from vk.com and output at mpd_now.artist and mpd_now.title showing full http:// patch to song. Can you advise how to do plugin with fixed width in tray? Or how to implement rotating to Artist - title ?