Author Topic: Color & font size format function  (Read 1845 times)

redwing

  • Hero Member
  • *****
  • Posts: 8894
How about supporting color & size format function for virtual tags?
For instance, $Format(<Title>,(255,0,0),12) would show title tag value in red color 12pt size.
This could be used for displaying various tags and also in any place where functions can be used like song info on the player bar.






Bee-liever

  • Member
  • Hero Member
  • *****
  • Posts: 3289
  • MB Version: 3.3.6910
+1
MusicBee and my library - Making bee-utiful music together

Steven

  • Administrator
  • Hero Member
  • *****
  • Posts: 28404
i think it will be useful to have control around this.
However i think i would implement as markup labels that are recognised in the text for a virtual tag eg.
Code
virtualTag1=<title>   {contrast: 30}[<artist>]
virtualTag2=<title>   {color: 201, 76, 76}{font: Arial bold 11}[<artist>]
the supported values would be:
Code
{color: r, g, b}
{font: name style size}
{contrast: n}
where contrast n=%value

I wont commit to implementing everywhere, at least for some time. Probably initially just the main panel file list, and sidebar playing tracks panel
Last Edit: March 05, 2018, 07:06:24 PM by Steven

redwing

  • Hero Member
  • *****
  • Posts: 8894
Any support would be great at this point. Once implemented, it could improve later.

boroda74

  • Hero Member
  • *****
  • Posts: 3066
it would be great to have some stack (some memory) of formatted values, eg.:
Code
virtualTag2=<title>   {color: 201, 76, 76}{font: Arial bold 11}[<artist>]{color:popup}[<album>]

boroda74

  • Hero Member
  • *****
  • Posts: 3066
probably its better just {color:default} rather than 'stack'

Steven

  • Administrator
  • Hero Member
  • *****
  • Posts: 28404
http://musicbee.niblseed.com/V3_2/MusicBee32_Patched.zip

as mentioned the markup is currently only supported in virtual tags in the track detail/ album & tracks views of the main panel or the playing tracks list
I changed the syntax of fonts slightly

Code
{color: r, g, b}
{color: default}
{font: name; style; size}
{font: default}
{contrast: n}
{contrast: default}

eg.
Code
virtualTag2=<title>   {color: 201, 76, 76}{font: Arial; regular; 11}[<artist>]{color:default}[<album>]

ost

  • Jr. Member
  • **
  • Posts: 76
I've noticed one strange thing: used tag is

<Track#> · <Title> · <Time>{color: 201,76,76}{font: Amazon Ember;Regular;9}$If(<Artist>=<Album Artist>,," · ["<Artist>])

Some random tracks looks strange:




Steven

  • Administrator
  • Hero Member
  • *****
  • Posts: 28404