Is there a way to orient text vertically instead of horizontally inside a label, or any other object that could be used in such a manner?
I'm trying to have a value written on a vertical gauge, but it looks ridiculous (and gets cut off) unless I make the gauge extremely wide.
Vertical Text in Labels
Re: Vertical Text in Labels
This may or may not work within Mudlet and I am unable to test, but try this:
Re: Vertical Text in Labels
So the text goes top to bottom or bottom to top instead of left to right? If you'd like text alignment within the label and wordwrap, see: http://wiki.mudlet.org/w/Manual:Geyser# ... de_a_label
Re: Vertical Text in Labels
So, I tried various strategies with QT alignment and word wrap, none of which worked as they don't break up a word. I also tried a few different HTML based strategies which also didn't work. In the end, the only thing that I have had any success with has been inserting <br> between each character of the string I want to display. Extremely ugly, but at least it works.
Re: Vertical Text in Labels
I recommend posting to Qt's mailing list in regards to this: http://lists.qt-project.org/mailman/listinfo/interest, they could know.
Re: Vertical Text in Labels
The current solutions for QT for writing text vertically involve rotating the painter that is being used to draw the text. I'm fairly certain I don't have access to the painter in Mudlet, and I tested to see if the suggested "rotation" property would work with a label anyway. It does not. Other suggestions are... inserting <br> between letters.
It does look like someone is experimenting with something to allow vertical text with QT, but that will no doubt be in a future version.
It does look like someone is experimenting with something to allow vertical text with QT, but that will no doubt be in a future version.
Re: Vertical Text in Labels
Alright, good to know. The painter indeed is inaccessible.
-
- Posts: 11
- Joined: Mon Dec 17, 2012 2:58 am
Re: Vertical Text in Labels
Have you considered just breaking up your words with newlines (\n), or does that not work on labels?
Re: Vertical Text in Labels
For some reason it was treating those as spaces instead of line breaks. But, from my end, inserting anything between letters is all the same. So putting in "\n" is no easier or harder than putting in "<br>", or even just " ". The only solutions that wouldn't require changing the original text would be a form of word wrap that would break words up (instead of only wrapping on white space), or rotating the text to write from top to bottom instead of left to right.