Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Menu with content depending on initial of word
#1
Hi Gintaras, hi all

i plan to automate some parts of the rip of my large CD collection.

What I want to do :

have a list (directly in QM or loaded from file, and trigerred by a TS menu.

Bach Jean-Sebastien Bach
Beethoven Ludwig van Beethoven
Bruckner Anton Bruckner
Mahler gustav Mahler
Monteverdi claudio Monteverdi
Mozart Wolfgang amadeus Mozart

When i launch the TS Menu trigger(**), followed by a single letter, it would give me a menu containing only the related composers.

Ex : trigger : **
then I press B
a menu shows only composers which names begin by B letter
after enter key for validation, it expands the whole name (Bach selected -> Jean-Sébastien Bach written).

I did not tried yet, just wanted to know if it possible.

Thanks
#2
Autotext Autotext
Trigger $t "**"     Help - how to add the trigger to the macro
Code:
Copy      Help
/b/i/c
b :"Jean-Sebastien Bach" ;;Bach
b :"Ludwig van Beethoven" ;;Beethoven
b :"Anton Bruckner" ;;Bruckner
m :"gustav Mahler"
m :"claudio Monteverdi"
m :"Wolfgang amadeus Mozart"
#3
Yes, i already use that trick, but thought there would be more flexible way, as loading
the TS menu items from file, as the name list can be rather long....
#4
Macro Macro1950
Code:
Copy      Help
out
;str s.getfile("...")
str s=
;Bach: Jean-Sebastien Bach
;Beethoven: Ludwig van Beethoven
;Bruckner: Anton Bruckner
;Mahler: gustav Mahler
;Monteverdi: claudio Monteverdi
;Mozart: Wolfgang amadeus Mozart

if(!s.replacerx("^(\w)(.+?): *([^\r\n]+)" "$1 :''$3'' ;;$1$2" 9)) end "incorrect list"
;out s
s-"/b/i/c[]"
s.setmacro("Autotext")
#5
Exactly what I wanted, thanks.

Q1: I suppose it's not possible to narrow the search with a second letter in the menu (if I press 'e' after b, then I have Beethoven or Berg, and not Brahms).

Q2: How long a TS menu can be (how many items can be shown)
#6
1. Not possible.

2. Many, but shows 9 items, then need to scroll. It is possible to resize: Auto Text - TS Menus Menu Listitem Limit
#7
I've got a full HD (1080 pixel high) laptop, should be enough room.


Forum Jump:


Users browsing this thread: 1 Guest(s)