Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Curious indexFormat Behaviour
12-04-2018, 10:36
Post: #1
Curious indexFormat Behaviour
I have a long Title.displayFormat defined in the tagFormat property that has required breaking down into two parts in order to give me the desired result in the display of the Title in my control points:

Title.displayFormat={$shortcomposer^^: $workmovement$titletag}

(titletag is an alias for title; shortcomposer is the composer's last name)

In turn, in front of this definition, the tag WorkMovement, declared in the indexTags property, is defined:

WorkMovement.indexFormat={$work^$movementnumber$movement^: ^^. }

It works well and removes extra spaces that eventuate if I try to define Title.displayFormat in one go.

The creation of the WorkMovement index is redundant for searching purposes (can one hide it?) but I had a look at the index generated anyway, expecting to see every track listed like:

Adagio and Allegro, Op. 70: 1. Langsam, mit innigem Ausdruck
Adagio and Allegro, Op. 70: 2. Rasch und feurig

For the most part, however, I'm seeing these entries melded thus:

Adagio and Allegro, Op. 70: 1. 2. Langsam, mit innigem Ausdruck. Rasch und feurig

The work and all its movements are on one line: work followed by all the movement numbers separated by full stops and spaces, then the movement names similarly separated.

It seems that something is broken, though as yet I have discerned no practical ramifications.
Find all posts by this user
Quote this message in a reply
13-04-2018, 08:20
Post: #2
RE: Curious indexFormat Behaviour
Do you have a GROUP tag for the work and all its movements?
Find all posts by this user
Quote this message in a reply
13-04-2018, 11:20
Post: #3
RE: Curious indexFormat Behaviour
Have you tried doing the following:

Title.displayFormat={$shortcomposer^^: ^$work^^: ^$movementnumber^^. ^$titletag}

Does this produce extra spaces? If so, where are they?
Find all posts by this user
Quote this message in a reply
13-04-2018, 16:28
Post: #4
RE: Curious indexFormat Behaviour
(13-04-2018 08:20)simoncn Wrote:  Do you have a GROUP tag for the work and all its movements?

Bingo! That's it. I removed the GROUP (usually set to reflect WORK) for some offending entries and the index displayed as expected.
Find all posts by this user
Quote this message in a reply
13-04-2018, 16:49
Post: #5
RE: Curious indexFormat Behaviour
(13-04-2018 11:20)simoncn Wrote:  Have you tried doing the following:

Title.displayFormat={$shortcomposer^^: ^$work^^: ^$movementnumber^^. ^$titletag}

Does this produce extra spaces? If so, where are they?

I think it's important to first understand the logic behind my tagging. And we know everyone has their own way...

TITLETAG is an alias for TITLE to avoid substituting the filename for empty TITLEs, thanks to your prior tip, Simon.

SHORTCOMPOSER may or may not be set.

WORK may or may not be set. It may be set without MOVEMENT and MOVEMENTNUMBER being set.

MOVEMENT may or may not be set. If it is set, so will WORK and MOVEMENTNUMBER be set.

TITLETAG may or may not be set. If WORK is not set, TITLETAG must be. But both may also be set. (In some collections of music, like Mendelssohn's Songs without Words, it's hard to think of each Song as a movement, in which case I leave each Song's title in the TITLETAG field).

So the first problem with your suggested displayFormat is that because the tags for MOVEMENT, MOVEMENTNUMBER and TITLETAG are not necessarily set, there may be a hanging colon after WORK.

This is why I prefix the $movementnumber$movement item with the colon, as these tags never exist without a WORK tag also existing (you've forgotten to include $movement in this item of your displayFormat).

It seemed to me that the only way to get everything displaying using just one displayFormat was with:

Title.displayFormat={$shortcomposer^^: $work^$movementnumber$movement^: ^^. $titletag^ }

But in this case, TITLETAG is always prefixed with a space and where there only exists a TITLETAG, then Title listings don't line up on the left edge of the control point display... Or there's an extra space in something like:

Bax: Mater Ora Filium (though that is not a biggie)

To get the displayFormat just right, I wanted to put a bracket around the WORK/MOVEMENT/MOVEMENTNUMBER items to evaluate them first and then I discovered that indexFormat effectively did this for me. I don't think I'm noticing any processing overhead that the manual talks about.
Find all posts by this user
Quote this message in a reply
14-04-2018, 20:59
Post: #6
RE: Curious indexFormat Behaviour
Thanks for this detailed information and for pointing out my unintended omission of $movement.

The problem with an initial space in the "only TITLETAG" case can be solved by MinimServer automatically stripping leading and trailing spaces from the formatted display value. This is already done for unformatted tag values.

The problem with the extra space between the $shortcomposer and $titletag values (where there is no work) can be solved by removing the space from the $shortcomposer suffix and prefixing $work with a space:

Title.displayFormat={$shortcomposer^^:$work^ $movementnumber$movement^: ^^. $titletag^ }

Would this handle all your combinations correctly?
Find all posts by this user
Quote this message in a reply
16-04-2018, 14:15
Post: #7
RE: Curious indexFormat Behaviour
Hi Simon,

Thanks for your suggestion. I just tried it. Where there is no SHORTCOMPOSER, but a WORK, with or without MOVEMENT, etc., there is a leading space in the control point for the Title.

Q
Find all posts by this user
Quote this message in a reply
16-04-2018, 19:52 (This post was last modified: 16-04-2018 19:53 by simoncn.)
Post: #8
RE: Curious indexFormat Behaviour
There is a leading space at the moment because MinimServer doesn't currently remove leading and trailing spaces from displayFormat values. If this were changed so that these spaces are removed, would everything be OK?
Find all posts by this user
Quote this message in a reply
18-04-2018, 13:09
Post: #9
RE: Curious indexFormat Behaviour
(16-04-2018 19:52)simoncn Wrote:  There is a leading space at the moment because MinimServer doesn't currently remove leading and trailing spaces from displayFormat values. If this were changed so that these spaces are removed, would everything be OK?

Ah, now I see what you mean in your 2nd paragraph above, penultimate post.

Your suggestion to remove trailing and leading spaces after formatting would seem to fix my problem and would probably be a logical step.

In the meantime, is there a way to hide the extra index I have created from the index displays but leave it available for Title.displayFormat...?
Find all posts by this user
Quote this message in a reply
18-04-2018, 13:26
Post: #10
RE: Curious indexFormat Behaviour
I will make the change to strip leading and trailing spaces from formatted values in the next MinimServer update. In the meantime, it isn't possible to specify indexFormat for a tag that doesn't have an index entry.
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)