INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: • MrC's Tip of the Week 2013.32: Display Area Customization  (Read 8384 times)

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.
• MrC's Tip of the Week 2013.32: Display Area Customization
« on: August 09, 2013, 06:26:27 pm »

I thought it might be fun to start out an MC Tip of the Week series.  Let's see how far it goes.  Let's see how useful it is.  Feel free to comment, add your suggestions and improvements.  Let's jump right in with the first tip...

Does that ever-shifting display status line at the top of the Player bar get under your skin?  If it doesn't... good - you're a better person than I am.  But if it irks you even a little, like it does me, you can fix it.

Why does it bounce around?  MC tries to center the text string, but the bitrate is a constantly changing width, using between 1 to 4 digits.  So the line is constantly in flux, especially for tracks whose bitrates bounce between n and n+1 digits.



The default status line shows the file's current playback bitrate using the pseudo-field [Bitrate (Labeled)].  We can customize the display status to reduce the bounce.  Right-click the Player's status, and select Customize Display...

Now, find the [Bitrate (labeled)] field in the Status line, under the Play Mode (Main) area.  Replace [Bitrate (labeled)] with the expression:

   mid(/ / / / , length([Bitrate]), -1)[Bitrate (Labeled)]

and OK your way out.  Be sure to copy and paste the expression above, as it contains some magic* characters that you won't notice just by examining the line with your eyes.

The expression determines the length of the [Bitrate] value, and then uses mid() to pad as necessary up to 4 characters so that the [Bitrate (Labeled)] value does not jump around (so much).  It is not perfect, but works pretty well.

* What are those magic characters?  They are a form of white space called a Figure Space (U+2007), and they are about as wide as regular characters, so are good for these types of padding needs.

Enjoy and have a good weekend.
Logged
The opinions I express represent my own folly.

r_harms

  • Junior Woodchuck
  • **
  • Posts: 67
Re: MrC's Tip of the Week 2013.32
« Reply #1 on: August 10, 2013, 10:43:59 am »

I think this is a great idea and I sure do appreciate your efforts!

Just learning of another area where an expression can be used gives me hope to expand on ideas of my own.

Maybe down the line you could do a couple examples of (very) simple RegEx expressions to give us some foundation to move forward on our own instead of us just begging you for use of your mind...

I've got MrC to thank for many of the things I've accomplished with Media Center. I've even managed to do a few recent ones without any direct help because I found examples and code from posts he had already offered up to the community.

Like I said, Many thanks!

Rick

Logged

jctcom

  • Citizen of the Universe
  • *****
  • Posts: 690
  • Rush - Styx - Yes - Porcupine Tree - Staple Food!
Re: MrC's Tip of the Week 2013.32
« Reply #2 on: August 10, 2013, 12:29:41 pm »

What he said.

Carl.
Logged
Carl's Music: https://cloud.clz.com/jctcom/music
Carl's Movies: https://cloud.clz.com/jctcom/movies

Some of Carl's Equipment:  Yamaha RX-A2A, i7-11700K, 128GB, PCIe X4 2TB M.2 SSD, GTX-970, SMSL DL200

Arindelle

  • Citizen of the Universe
  • *****
  • Posts: 2772
Re: MrC's Tip of the Week 2013.32
« Reply #3 on: August 10, 2013, 01:21:12 pm »

Yep me too MrC -- another good idea.... keep 'em coming, I'll stay tuned.  :)
Logged

terrym@tassie

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 505
Re: MrC's Tip of the Week 2013.32
« Reply #4 on: August 11, 2013, 05:25:17 pm »

Briliant idea- I go as far as to say that we could do with a separate board to contain discussion on MC customisation using expressions, Theaterview, tagging etc.
I'm sure there must be loads of good stuff that folks have developed and uncovered that could then be used by other users.
I've got some niche stuff to do with correctly tagging downloaded BBC TV and Radio programmes and displaying them nicely in Theaterview (Theatreview for BBC of course) for example.
I think this sort of stuff can get "lost" on the main board.
Logged
Good manners cost nothing.
Bad manners can cost you your reputation
― B.D.Hawkey

Gl3nn

  • Galactic Citizen
  • ****
  • Posts: 384
Re: MrC's Tip of the Week 2013.32
« Reply #5 on: August 11, 2013, 07:59:54 pm »

Thanks, MrC.

Great idea.  Please keep it coming.
Logged

filupmarley

  • Recent member
  • *
  • Posts: 17
Re: MrC's Tip of the Week 2013.32
« Reply #6 on: August 11, 2013, 09:30:12 pm »

This is great! Thanks MrC
Logged

astromo

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2251
Re: MrC's Tip of the Week 2013.32
« Reply #7 on: August 12, 2013, 02:57:50 am »

Great stuff.

Where do I sign up to this as an RSS feed?   8)
Logged
MC33, Win10 x64, HD-Plex H5 Gen2 Case, HD-Plex 400W Hi-Fi DC-ATX / AC-DC PSU, Gigabyte Z370 ULTRA Gaming 2.0 MoBo, Intel Core i7 8700 CPU, 4x8GB GSkill DDR4 RAM, Schiit Modi Multibit DAC, Freya Pre, Nelson Pass Aleph J DIY Clone, Ascension Timberwolf 8893BSRTL Speakers, BJC 5T00UP cables, DVB-T Tuner HDHR5-4DT

Samson

  • Galactic Citizen
  • ****
  • Posts: 391
Re: MrC's Tip of the Week 2013.32
« Reply #8 on: August 13, 2013, 06:19:23 am »

Keep 'em coming MrC, !
Logged

nels

  • Recent member
  • *
  • Posts: 20
Re: MrC's Tip of the Week 2013.32
« Reply #9 on: August 13, 2013, 08:19:47 am »

Is there a way to push a setting like this to the client?
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.
Re: MrC's Tip of the Week 2013.32
« Reply #10 on: August 13, 2013, 09:16:48 am »

Open up this page on the client, and copy/paste.  :-)
Logged
The opinions I express represent my own folly.

nels

  • Recent member
  • *
  • Posts: 20
Re: MrC's Tip of the Week 2013.32
« Reply #11 on: August 15, 2013, 01:30:59 pm »

Thanks MrC. This doesn't work on MC19. I changed the expression back to [Bitrate (labeled)] and that doesn't work either. Nothing displays. This is with flac after running Audio Analysis with MC19.
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: MrC's Tip of the Week 2013.32
« Reply #12 on: August 15, 2013, 01:32:01 pm »

Thanks MrC. This doesn't work on MC19. I changed the expression back to [Bitrate (labeled)] and that doesn't work either. Nothing displays. This is with flac after running Audio Analysis with MC19.

Remember that real-time bitrate is not available with memory playback enabled:
http://yabb.jriver.com/interact/index.php?topic=81982.0
Logged
Matt Ashland, JRiver Media Center

nels

  • Recent member
  • *
  • Posts: 20
Re: MrC's Tip of the Week 2013.32
« Reply #13 on: August 15, 2013, 01:38:22 pm »

thanking you
Logged

thediscman

  • Regular Member
  • Junior Woodchuck
  • **
  • Posts: 51
  • Change this by choosing profile
Re: • MrC's Tip of the Week 2013.32: Display Area Customization
« Reply #14 on: January 21, 2014, 05:11:23 pm »

Thank you so much! I was looking for *exactly* this.

I added Dynamic Range (with a label) to my second line display and the bitrate field was causing my newly expanded line to shift around so much that I just removed bitrate. Thanks to your tip, I can put it back in.  ;D
Logged
Pages: [1]   Go Up