Forum Discussion

jshutters's avatar
jshutters
Resolver I
6 years ago
Solved

Is there a better way to R-align text labels?

Is there a better way to R-align text labels?

My goal is to find visual(s) to display 2 text labels with the following conditions:

  1. 2 texts (i.e. Acme Corp, Acct 123456) are right aligned, as shown in the screen shot below.
  2. They will have a different font size from each other (i.e. 20 and 14 pt)
  3. Their font family is Helvetica Neue (which I leverage a JSON file)
  4. The labels can fit nicely & look good in the report.
  5. The values are dynamic and come from the database.
  6. I use standard out of the box or certified PBI visuals.

 

Here's what I've tried and why it doesn't work:

  1. Standard Card visuals don't offer R-alignment.
  2. A single table or matrix visual doesn't allow labels to have different font sizes
  3. Advance Card (certified from the library) ignores my JSON theme file with Helvetica Neue font.
  4. advanceCardE03760C5AB684758B56AA29F9E6C257B (suggested from another community post) isn't certified.
  5. 2 similar matrix visuals, one for each label, with Values-Show on rows, grid lines off, background off, etc... This ALMOST works for me, but it maintains a gap/spacing at the top that I can't get rid of, thus it doesn't fit nicely in the report.

How can I make this work?

  • I have a solution to my R-alignment challenge. Buttons!!! I use 2 blank buttons, and set the Button Text to be Conditional Formatting based upon fields from my data source. I turn off the Outline, Background, etc... so it blends in perfectly.

    The only short-coming is that the button's font family doesn't pickup the font family from my JSON file (Helvetica Neue), but I've heard Microsoft will fix this in the next few months. In the meantime, I'll use the standard Times New Roman.

3 Replies

  • v-juanli-msft's avatar
    v-juanli-msft
    Community Support

    Hi jshutters 

    I use standard card visual, i could select two card visuals and select "View"->"Align"->"Align right".

    Best Regards
    Maggie
    Community Support Team _ Maggie Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • jshutters's avatar
      jshutters
      Resolver I

      Thanks for your reply, Maggie.  But that idea doesn't work, per item #1 above (standard cards don't R-align the data label).  While it is true that I can R-align the edges of multiple visuals, and it'll look good for the first database value (e.g. Acme Corp), the labels will be immediately out of alignment once the database values change (e.g. Joe's Co.).  See screen shot.  Any more ideas?

       

      • jshutters's avatar
        jshutters
        Resolver I

        I have a solution to my R-alignment challenge. Buttons!!! I use 2 blank buttons, and set the Button Text to be Conditional Formatting based upon fields from my data source. I turn off the Outline, Background, etc... so it blends in perfectly.

        The only short-coming is that the button's font family doesn't pickup the font family from my JSON file (Helvetica Neue), but I've heard Microsoft will fix this in the next few months. In the meantime, I'll use the standard Times New Roman.