it would be nice to have the text editor be able to center the edited text inside. (useful for controllers)
and perhaps a right to left alignment can be nice for right to left languages.
cheers!
thanks!
Assaf
it would be nice to have the text editor be able to center the edited text inside. (useful for controllers)
and perhaps a right to left alignment can be nice for right to left languages.
cheers!
thanks!
Assaf
Yes, Iāve got some code to do that, which Iāve been meaning to merge inā¦
yay you rock!
I just spent time looking for a way to do alignment or justification with a TextEditor component, and came to this thread.
Iād like to second the motion for left, right and center alignment of text.
was this done ? i canāt find anything about justification in the TextEditor class.
I donāt think I ever added it (ā¦?)
could you ?
or was there a problem and it canāt be done.
I think it was just a bit of a PITA to write, and I never got round to it. It is still there on my to-do-list.
Not to hijack, but whatās the possibility of adding unicode(MLTE) text entry to texteditor? Iād fly to the UK and hug your feetā¦not much of an incentive i know, butā¦
on the subject of PITA, apart from beeing a urban dictionary acronym for pain in the ass itās also a type of food, that was sold in all theese little booths on the central train station in a town i used to live in. there was like 20-30 of theese booths and they all sold this
it had this white sauce in it, that got everywhere but your mouth. at some point someone got interested in this fenomen (it got very popular) and did a test on what did those PITA sandwiches contain. Apart from the obvious unhealthy chemicals and rotten veggies it also contained some amounts of Sperm, but the most interesting part (if that wasnāt enough) is that it was HORSE sperm (i always thought it would be human, some bored sauce maker person getting off on the job).
I just wanted to tell you that PITA can mean both of theese things.
And it it comes to foot fetish stuff, i offer my services as well.
(I thought that was spelt āpittaāā¦?)
Itās already unicode, of course - so do you mean right-to-left layout?
Hey Jules. I mean multiple language text input. So if I swap to say hiragana keyboard layout and type puru I get ć·ć
the two āwesternā characters pu make the first symbol and ru the next. Itās not just Asian characters but scandanivian as well (and others needing two or more keystrokes)
on cocoa an nsview is too lowlevel I think(on a keydown). An nstextview works but then weād lose the functionality of your texteditor. Carbon had an interface that worked without a control but we obviously want to get away from that
iāll happily spend some time on the mac side if someone wants to suggest windows/Linux trappings(Iād hate to waste time if it couldnāt be rolled into juce platforms)
Iāve seen someone work around it on iPhone by using a hidden nstextview equivalent to trap the events and then forward the Unicode string to the control.
Hey Jules. I mean multiple language text input. So if I swap to say hiragana keyboard layout and type puru I get ć·ć
the two āwesternā characters pu make the first symbol and ru the next. Itās not just Asian characters but scandanivian as well (and others needing two or more keystrokes)
on cocoa an nsview is too lowlevel I think(on a keydown). An nstextview works but then weād lose the functionality of your texteditor. Carbon had an interface that worked without a control but we obviously want to get away from that
iāll happily spend some time on the mac side if someone wants to suggest windows/Linux trappings(Iād hate to waste time if it couldnāt be rolled into juce platforms)
Iāve seen someone work around it on iPhone by using a hidden nstextview equivalent to trap the events and then forward the Unicode string to the control.
Sorry about the double post(mobile safari).
From what I know every nswindow has a nstextview that is used for all key entry. When an nstextfield, nstextfieldcell goes into edit mode this controls go visible and moves into position. For the character palette to work(which it currently doesnāt with juce) Iām not sure what the os is looking for. (as a test call up the character palette and try to insert Unicode characters/symbols)
anyway if I find more info Iāll create a new post
NSTextInput Protocol Reference seems to be promising (NSTextInputClient on >10.5). Adding the functions to JuceNSView might do the trick
Appleās links donāt seem to last long these days but here it is for what its worth
I might have to do something like this this weekā¦if I do iāll contribute any code
Thanks - thatās all new to me, Iāll have to take a look.
Iāve hacked something together in NSViewComponentPeer, iāll send you off listā¦
It currently looks for the focused component to be able to be dynamically cast to TextEditor before passing the events for interpretation.
Ok, thanks, Iād be interested to see that.
Hi there, just wondering if this was ever added.
yes, me too. Did the code went into the current version ? I would like to be able to center-align and right-align the text in a TextEditor.