Selecting "frame" in Chord symbol text style has no effect.

• Apr 23, 2014 - 23:35
Type
Functional
Severity
S4 - Minor
Status
closed
Regression
No
Workaround
No
Project

MuseScore fe9152137c

  1. Create a score with a couple of chord symbols
  2. Right click one -> Text style
  3. check the frame checkbox and change the frame width
  4. Press OK

Expected result: a frame around the chord symbols
Actual result: no frame


Comments

BTW, it should be noted that merely checking the "frame" box isn't good enough - you need to set a non-zero line width. I suppose we could consider having all text styles default to some reasonable value here (same for margin) or users may wonder why this checkbox doesn't seem to do anything. It should work to just make these values the defaults; as long as "frame" itself defaults to off, there should be no effect, and with any luck it might not even break many tests?

Weird! Well, it's not that big a deal - people hopefully figure out they need to set a width when it ungreys. But speaking for myself, I didn't figure it out until it didn't work after I thought I got the implementation right, and I stepped through with the debugger to find out why not, and found width == 0 :-)

I guess we could have the act of checking the "frame" box set the other fields if they are still on their default values.

On a related note, if you select "circle" instead of "box", the radius value affects nothing. The circle size is still the margin value from the box settings.

The "Width" value applies to both Circle and Box, and so does Foreground and Background color. But the values for Radius and Margin don't, so might I suggest a dialog re-arrangement?

[x] Frame Width: [ 0.10sp ]
Foreground color: xxx Background color: xxx

(o) Circle (o) Box
Radius:[ 25 ] Margin: [ 0.10sp ]

Some questions:

1. What units is "radius" in?

2. The margin seems to start and increase much to fast, by .5sp. Might I suggest increments of .25sp, or even .1sp?

3. Same goes for the horizontal and vertical adjustments, moving by 1sp at a time. A smaller increment might be better for finer adjustments.

In 170d710cb7 the default width and margin of frame are changed.

I also address schepers 2 and 3. Also the radius is now disabled when circle is selected and I changed the names for "border radius" and "border width"...

Regarding 1/, I'm not sure what the radius unit is...

We are using http://qt-project.org/doc/qt-4.8/qpainter-obsolete.html#drawRoundRect which is an obsolete function. https://github.com/musescore/MuseScore/blob/master/libmscore/text.cpp#L…

Maybe we should use http://qt-project.org/doc/qt-5/qpainter.html#drawRoundedRect and Qt::RelativeSize now.

Thanks for the changes! Things are better, but... might I suggest a few more improvements?

1. Right now, selecting Circle, the radius value in greyed and unavailable, but the Text Margin is available. Select Box, and Radius is enabled along with Text Margin. Shouldn't Radius only apply to Circle and Text Margin only apply to Box?

2. If you enable Frame on one chord, it is enabled for future ones. I doubt this is what is wanted.

3. Default Border Width is .2. That seems a bit thick, can .1 be default?

4. Default Text margin is .5. That seems quite far away, can it be .2? (Existing defaults for 3 and 4 combined take a bit of real estate, hence the change in defaults)

5. Can the default be set to Box?

About the re-arrangement, I was kind-a hoping that things would be more re-arranged, grouped by use, like this:

141.png

Attachment Size
141.png 27.59 KB

Regarding point 2) above, that's correct and intended. This is the *text style* dialog. It affects all elements that are assigned that style, whether already existing or yet to be created. This is the whole point of the text style system in 2.0. You may be thinking of the separate "text properties* dialog that allows you to override these settings for individual elements, but that dialog is not available for chord symbols, since they are rendered completely differently from other text.

As for the defaults, box *is* the default, at least it seems to me for me. As for thickness and margins, 0.2 and 0.5 make sense to me, although this probably depends on your intended use. These are the current defaults for rehearsal marks; 1.3 actually has 0.3 and 1.00 which I thought were too big.

Marc, good point about this being the Text Style dialog, I missed that.

Regarding "Box" being default, I think you are right, but I don't think it was before.

I'm not convinced that the size/spacing defaults are good. I certainly _don't_ want boxes around chords looking anything like rehearsal marks. T'would cause too much confusion.

I think you are right about the default not being box earlier.

Good point about chord symbols looking like rehearsal marks. I actually wasn't thinking about chord symbols specifically. The change here affects *all* text types, and I'm guessing it's going to be at least as common to want to box staff or tempo text as chord symbols. I do think the current default is generally pleasing. Maybe have chord symbols have different defaults from everything else, since they are really the main text likely to be mistaken for rehearsal marks otherwise?

But actually, I think the intended use case is to support E-Z Play notation, which is the main real-world example I know of that uses boxed chords. And actually, the current defaults look about right to me, aside from the box being more rounded than the example:

I suspect rehearsal letters aren't used in this particular style of notation.

If there is another style more notation more common than E-Z Play that uses boxed chords, and that style uses a different shape box, perhaps that could be considered as a default. But assuming E-Z Play is the main use case, I think the current defaults might make most sense (aside from perhaps reducing the radius)

Understood about the use for chord boxes.

However, the dialog still has some issues, esp Border Radius not being available for Circle, but all options being available for Box. Some tweaks and we're good.

Border radius (as maybe the name doesn't imply if you know nothing about CSS) makes sense only for Boxes. It's the radius used to make the rounded corder of the rectangle. There is no way to set the radius of the Circle itself but using the margin around the text. That's why frame width and margin are enabled for both box and circle and border radius for box only to be able to control the rounded corner.

http://www.w3schools.com/cssref/pr_border-width.asp
http://www.w3schools.com/cssref/css3_pr_border-radius.asp

If we need to discuss further the wording etc... it would be better to open a forum thread on the tech preview forum http://musescore.org/en/forum/687

Ah, the lights are coming on! Now I see what the various adjustments do. Regarding naming, the tooltips text seem to make more sense than the UI naming.

Border width=Frame Line Width (or even just Width)
Text Margin=Frame Inner Margin (or even Dist. from text)
Border Radius=Corner Round (or Corner Radius, still not the best name, but this one is hard to name)

I started a forum discussion on the border radius parameter - not the naming, but the behavior:

http://musescore.org/en/node/25558

I propose replacing drawRoundRect with drawRoundedRect and adding a new text style parameter to control whether this function is called with Qt::RelativeSize or not. I think this new parameter should default to "yes" for 1.X scores for compatibility. But I think the default should be "no" for new scores, since I think the behavior without that option is actually better, if different from 1.X.