There is #pendingText to access it, finally found that. Now I want to detect when someone starts typing and do actions (like disable something until the text is accepted). There is��whenTextChanged: but it���s not that useful because it checks if the accepted text has changed. Is there a way to check if pendingCode has changed? Or if the model is entering ���hasUnacceptedEdits���?
UkoOn 24 Jul 2016, at 12:48, Yuriy Tymchuk <yuriy.tymchuk@me.com> wrote:Cool. Thank you Nicolai. While we are on this, is there an example of how to display the parsing/compilation error as is done in playground?UkoOn 24 Jul 2016, at 11:37, Nicolai Hess <nicolaihess@gmail.com> wrote:2016-07-24 11:35 GMT+02:00 Nicolai Hess <nicolaihess@gmail.com>:2016-07-24 11:14 GMT+02:00 Yuriy Tymchuk <yuriy.tymchuk@me.com>:Hi,
at some moment I wrote a super angry comment about Spec. But as there is a big effort put into documentation & improving the framework I���ve decided to give it another try.
And guess what, after 10 min I ran into yet one more problem. I was expecting that it will be tough to have a custom styling for code, but no it���s much simpler: how do I get a text from text model? I type something in, sent #getText to the model => nothing. I expect that the problem is that the text is not accepted��� Why in the first place a basic text model needs this ���accept��� stuff? What if I have just a dialog where someone types something and submits it? I don���t need accepts with orange corners for that.
textmodel autoAccept: true.
��
I think that you���ve got the idea. I just want to build a simple UI and it looks like it���s easier to do it with Morphic���
Cheers.
Uko
But I agree, it is not *that* obvious and I think the behavior even changed as we replaced the PluggableTextMorph with Rubric ones - (maybe?)Anyway, maybe we need a way to distinguish between- get visible text (view get text?)and- get accepted text (model get text?)nicolai