TxText model

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
78 messages Options
1234
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)
 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.
Does it means it can serve as a base of full-fledged word processing software in a future? Sure thing. Why not?

But does it means i should care or have interest in pursuing that direction? No. It is not on my radar and not among my interests.
 
Regards,

Thierry




--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko
In reply to this post by Stephan Eggermont-3


On 4 April 2016 at 16:41, Stephan Eggermont <[hidden email]> wrote:
On 04-04-16 14:49, Igor Stasenko wrote:
Oh, and aside all of that.. Making a full-fledged word processor is not
just a regular engineering task. You need an expert of publishing, expert
in fonts and typography. That's right from the beginning.
And i am not that expert in this domain(s).
So, next time, when we start talking about things like page layouts,
columns, margins, tabs, references and other stuff, first find an expert
who will be able to transform these terms into technical requirements.
If you think it so simple, it is not: because all those terms came from
paper-publishing domain, that existed even before first computer came to
existence.
The capabilities of TxText and whether it will be capable to handle well
complexities of full-fledged word processing features, at this point,
without having an expert is nothing but just a speculation.

I know enough about typesetting and producing technical documentation.

And i have no idea what typesetting means. I can only guess , since it is compound from familiar 'type' and 'setting' words.
And technical documentation.. now i start having a headache :)
 
Stephan





--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

philippe.back@highoctane.be


On Apr 4, 2016 3:54 PM, "Igor Stasenko" <[hidden email]> wrote:
>
>
>
> On 4 April 2016 at 16:41, Stephan Eggermont <[hidden email]> wrote:
>>
>> On 04-04-16 14:49, Igor Stasenko wrote:
>>>
>>> Oh, and aside all of that.. Making a full-fledged word processor is not
>>> just a regular engineering task. You need an expert of publishing, expert
>>> in fonts and typography. That's right from the beginning.
>>> And i am not that expert in this domain(s).
>>> So, next time, when we start talking about things like page layouts,
>>> columns, margins, tabs, references and other stuff, first find an expert
>>> who will be able to transform these terms into technical requirements.
>>> If you think it so simple, it is not: because all those terms came from
>>> paper-publishing domain, that existed even before first computer came to
>>> existence.
>>> The capabilities of TxText and whether it will be capable to handle well
>>> complexities of full-fledged word processing features, at this point,
>>> without having an expert is nothing but just a speculation.
>>
>>
>> I know enough about typesetting and producing technical documentation.
>>
> And i have no idea what typesetting means. I can only guess , since it is compound from familiar 'type' and 'setting' words.
> And technical documentation.. now i start having a headache :)

Is TxText part of the image?
Any configuration?

Phil
>  
>>
>> Stephan
>>
>>
>
>
>
> --
> Best regards,
> Igor Stasenko.

Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by Igor Stasenko


2016-04-04 15:49 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)

Yes, diagrams :) Ok, I don't know that much Pillar in details myself; except as one of those things where some of your characters in the text are used to build a layout on a target.

 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.

I'd say it is more: it is an interactive model for text editing and rendering. How much of it is "interactive" by opposition to pure rendering? Can they be easily separated?
 
Does it means it can serve as a base of full-fledged word processing software in a future? Sure thing. Why not?

Ok.
 
But does it means i should care or have interest in pursuing that direction? No. It is not on my radar and not among my interests.

You made that point clear :)

Regards,

Thierry
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko
In reply to this post by Igor Stasenko


On 4 April 2016 at 16:49, Igor Stasenko <[hidden email]> wrote:


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)
 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.
Does it means it can serve as a base of full-fledged word processing software in a future? Sure thing. Why not?

But does it means i should care or have interest in pursuing that direction? No. It is not on my radar and not among my interests.
 
.. My interest was to migrate Pharo to run using vector-based graphics. And without text rendering, that apparently would be incomplete.
What you can do on top of that, is beyond that scope. My personal interest and interest of our team was to make a platform, so you can do it yourself.
 
Regards,

Thierry




--
Best regards,
Igor Stasenko.



--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by philippe.back@highoctane.be


2016-04-04 16:02 GMT+02:00 [hidden email] <[hidden email]>:


On Apr 4, 2016 3:54 PM, "Igor Stasenko" <[hidden email]> wrote:
>
>
>
> On 4 April 2016 at 16:41, Stephan Eggermont <[hidden email]> wrote:
>>
>> On 04-04-16 14:49, Igor Stasenko wrote:
>>>
>>> Oh, and aside all of that.. Making a full-fledged word processor is not
>>> just a regular engineering task. You need an expert of publishing, expert
>>> in fonts and typography. That's right from the beginning.
>>> And i am not that expert in this domain(s).
>>> So, next time, when we start talking about things like page layouts,
>>> columns, margins, tabs, references and other stuff, first find an expert
>>> who will be able to transform these terms into technical requirements.
>>> If you think it so simple, it is not: because all those terms came from
>>> paper-publishing domain, that existed even before first computer came to
>>> existence.
>>> The capabilities of TxText and whether it will be capable to handle well
>>> complexities of full-fledged word processing features, at this point,
>>> without having an expert is nothing but just a speculation.
>>
>>
>> I know enough about typesetting and producing technical documentation.
>>
> And i have no idea what typesetting means. I can only guess , since it is compound from familiar 'type' and 'setting' words.
> And technical documentation.. now i start having a headache :)

Is TxText part of the image?

It is. Five packages, 1609 + 2647 lines of code (excluding tests and styler).

I think Denis has worked on it (and extended it).

Thierry

Any configuration?

Phil
>  
>>
>> Stephan
>>
>>
>
>
>
> --
> Best regards,
> Igor Stasenko.


Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Stephan Eggermont-3
In reply to this post by Stephan Eggermont-3
On 04-04-16 13:18, Stephan Eggermont wrote:

> On 04-04-16 11:58, Igor Stasenko wrote:
>> Apart from being 'cool to have', full-fledged word processing is not
>> a thing, that you dealing with on a daily basis in environment, like
>> Pharo.
> I'm sure that is the case for you. I wonder if that is the case for
> many Pharo users.
> AFAIK there are a lot of pillar users.
>
> For me the problem with the TxText model is that it blocks the
> possibility of doing
> that later, if and when there is enough development capacity to invest
> in this.
Sorry Igor, I got confused by the moveDown: of TxTextPosition, and only
later realized
there is TxAthensLayoutPosition. I retract that statement.

Stephan


Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko
In reply to this post by Thierry Goubier


On 4 April 2016 at 17:03, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:49 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)

Yes, diagrams :) Ok, I don't know that much Pillar in details myself; except as one of those things where some of your characters in the text are used to build a layout on a target.

 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.

I'd say it is more: it is an interactive model for text editing and rendering. How much of it is "interactive" by opposition to pure rendering? Can they be easily separated?

Well, there is a model, TxModel, which is domain-based. Means it is abstract and agnostic from any kind of rendering engine or UI.
It represents an object that contains text and allows certain operation on it, like selection, deletion, insertion etc.
And rendering engine bridges that model with morphic and athens.
It cannot be separated, since it implies using such model for computing layout, and implies to use Athens for rendering.. And implies to exist in Morphic (or some other kind of UI environment) for UI interaction, to be represented as a widget on screen and receive events and mouse/keyboard input etc. 
So, what kind of separation you trying to see there?
 
 
Does it means it can serve as a base of full-fledged word processing software in a future? Sure thing. Why not?

Ok.
 
But does it means i should care or have interest in pursuing that direction? No. It is not on my radar and not among my interests.

You made that point clear :)

Regards,

Thierry



--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Stephan Eggermont-3
In reply to this post by Thierry Goubier
On 04-04-16 15:49, Thierry Goubier wrote:
> Are you thinking of writing a text typesetting engine in Pharo?

Would I like to? Sure. Don't know how to finance that, though.

Stephan



Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Sven Van Caekenberghe-2
In reply to this post by philippe.back@highoctane.be

> On 04 Apr 2016, at 16:02, [hidden email] <[hidden email]> wrote:
>
> Is TxText part of the image?

Try (in 5.0):

TxViewContainer exampleOneLineEditor.

TxViewContainer editText: 'Philippe Back'.

Sven
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by Igor Stasenko


2016-04-04 16:14 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 17:03, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:49 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)

Yes, diagrams :) Ok, I don't know that much Pillar in details myself; except as one of those things where some of your characters in the text are used to build a layout on a target.

 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.

I'd say it is more: it is an interactive model for text editing and rendering. How much of it is "interactive" by opposition to pure rendering? Can they be easily separated?

Well, there is a model, TxModel, which is domain-based. Means it is abstract and agnostic from any kind of rendering engine or UI.
It represents an object that contains text and allows certain operation on it, like selection, deletion, insertion etc.
And rendering engine bridges that model with morphic and athens.
It cannot be separated, since it implies using such model for computing layout, and implies to use Athens for rendering.. And implies to exist in Morphic (or some other kind of UI environment) for UI interaction, to be represented as a widget on screen and receive events and mouse/keyboard input etc. 
So, what kind of separation you trying to see there?

I was trying to evaluate how much of it was tied to an underlying text model, and a specific interaction approach / global high level view of the UI.

A short look through the layout part of it and I saw it has support for arbitrary object spans. It also supposes a certain API from it's model (interacting back to indicate where lines should be ended). A text is a list of spans, isn't it? And spans are flat (no span inside span). One could imagine extending attributes for spans / type of spans and get customized rendering / handling for those.

For now, external objects can't extend below the baseline.

Position inside spans can be ambiguous: last position of a span and first position of the next span are the same position.

Thierry
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Denis Kudriashov
In reply to this post by Thierry Goubier

2016-04-04 16:11 GMT+02:00 Thierry Goubier <[hidden email]>:
It is. Five packages, 1609 + 2647 lines of code (excluding tests and styler).

I think Denis has worked on it (and extended it).

History was that:
At some point I realised that I can't use old TextMorph anymore. For my project I needed flexible editors which allows me implement validation, mask fields, secrete fields and others. It was almost impossible to hack old text morph to support these features. 
I read about Igor project TxText. It included only model at that time which was very similar to my ideas. So I decided to implement editors on top of it. I was try to not touch model itself and only fix bugs. But during development I saw all weakness of model and I start refactoring with idea of active text which announces any changes.
And in same time Igor returned to this project. He saw all problems with model and started refactoring too. But his idea was opposite to my. 
At the end I forked my refactored version of TxText into separate project Twisty. So I think current TxText not includes any my code.


Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by Stephan Eggermont-3


2016-04-04 16:04 GMT+02:00 Stephan Eggermont <[hidden email]>:
On 04-04-16 15:49, Thierry Goubier wrote:
Are you thinking of writing a text typesetting engine in Pharo?

Would I like to? Sure. Don't know how to finance that, though.

Framemaker-like or web-page like?

Thierry
 


Stephan




Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by Denis Kudriashov


2016-04-04 16:47 GMT+02:00 Denis Kudriashov <[hidden email]>:

2016-04-04 16:11 GMT+02:00 Thierry Goubier <[hidden email]>:
It is. Five packages, 1609 + 2647 lines of code (excluding tests and styler).

I think Denis has worked on it (and extended it).

History was that:
At some point I realised that I can't use old TextMorph anymore. For my project I needed flexible editors which allows me implement validation, mask fields, secrete fields and others. It was almost impossible to hack old text morph to support these features. 
I read about Igor project TxText. It included only model at that time which was very similar to my ideas. So I decided to implement editors on top of it. I was try to not touch model itself and only fix bugs. But during development I saw all weakness of model and I start refactoring with idea of active text which announces any changes.
And in same time Igor returned to this project. He saw all problems with model and started refactoring too. But his idea was opposite to my. 
At the end I forked my refactored version of TxText into separate project Twisty. So I think current TxText not includes any my code.

Twisty renders only on Athens too? Twisty is on Smalltalkhub, right?

Thierry

Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Denis Kudriashov

2016-04-04 16:51 GMT+02:00 Thierry Goubier <[hidden email]>:
Twisty renders only on Athens too? 

Only Morphic now. It should not be hard to support Athens, TxText can be used as example.

Twisty is on Smalltalkhub, right?

Yes
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko
In reply to this post by Thierry Goubier


On 4 April 2016 at 17:47, Thierry Goubier <[hidden email]> wrote:


2016-04-04 16:14 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 17:03, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:49 GMT+02:00 Igor Stasenko <[hidden email]>:


On 4 April 2016 at 16:32, Thierry Goubier <[hidden email]> wrote:


2016-04-04 15:23 GMT+02:00 Igor Stasenko <[hidden email]>:


Analogies don't work. Right :) I never used Pillar and have remote ideas about what it does or requires. From that perspective you appeal to wrong person. On your place i would be asking a guy who knows Pillar innards about it.
Forgive my ignorance.. but i am not omniscient.

False humility doesn't work there, Igor :)

But i don't know what Pillar is. Never used it. I'm not lying here. I seen people doing something with it time to time.. but never got my eyes on it. 
Or would you prefer that i would pretend that i know something and can continue discussion about things related to it? Waving hands, pointing to milestones, drawing diagrams? :)

Yes, diagrams :) Ok, I don't know that much Pillar in details myself; except as one of those things where some of your characters in the text are used to build a layout on a target.

 
 
 
Second is: Pharo (and all smalltalks) is the place where supposedly impossible stuff can be developed, simply because it takes far less lines than anywhere else. No guarantees, but, at the rate we're dropping projects by the side of the road (and reinventing stuff multiple times over), we have manpower to spare :)

But that is orthogonal. It is possible to do anything on turing-complete environment. Taking shortcuts etc etc yadda yadda. Now do such statements alone can bring us anywhere closer to grand goals and grand projects?
Nope. Only hard day to day work could bring us there.. Not talks about how cool we are.

Hard day to day work, yes. But if you make it that uninteresting, yes, I'm sure we will never get there :)

Okay, let me elaborate what was the whole point behind TxText project.
It was part of work we were doing to migrate from old Canvas & BitBlt Morphic rendering towards vector-based rendering using Athens. Basically in a nutshell TxText is a model and rendering engine for text rendering.

I'd say it is more: it is an interactive model for text editing and rendering. How much of it is "interactive" by opposition to pure rendering? Can they be easily separated?

Well, there is a model, TxModel, which is domain-based. Means it is abstract and agnostic from any kind of rendering engine or UI.
It represents an object that contains text and allows certain operation on it, like selection, deletion, insertion etc.
And rendering engine bridges that model with morphic and athens.
It cannot be separated, since it implies using such model for computing layout, and implies to use Athens for rendering.. And implies to exist in Morphic (or some other kind of UI environment) for UI interaction, to be represented as a widget on screen and receive events and mouse/keyboard input etc. 
So, what kind of separation you trying to see there?

I was trying to evaluate how much of it was tied to an underlying text model, and a specific interaction approach / global high level view of the UI.

A short look through the layout part of it and I saw it has support for arbitrary object spans. It also supposes a certain API from it's model (interacting back to indicate where lines should be ended). A text is a list of spans, isn't it? And spans are flat (no span inside span). One could imagine extending attributes for spans / type of spans and get customized rendering / handling for those.

Correct.
 

For now, external objects can't extend below the baseline.

Slightly not like that. An external object are bound to concrete position in text. And layout of a single line are computed based on dimensions of that object, as well as dimensions of other parts of a line. The text flow are not affected by the object in terms that there is no capability to compute wrapping text around it or align it left/right whatever separately from text. It means that basically external object is like a special kind of glyph/icon that uses same layout rules as character glyphs, but just rendered separately. 
 

Position inside spans can be ambiguous: last position of a span and first position of the next span are the same position.

Well, for some operation the are treated as same, for some - don't.
Since there's nothing can be between two positions at the ends of adjacent spans, from standpoint of user they represent same position in text. But from standpoint of model they are different since position are belong to different spans.
Sure thing, there certain pieces added to avoid problems with such ambiguity, so that it don't causing problems on user-level.

Thierry



--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

philippe.back@highoctane.be
In reply to this post by Sven Van Caekenberghe-2


On Apr 4, 2016 4:24 PM, "Sven Van Caekenberghe" <[hidden email]> wrote:
>
>
> > On 04 Apr 2016, at 16:02, [hidden email] <[hidden email]> wrote:
> >
> > Is TxText part of the image?
>
> Try (in 5.0):
>
> TxViewContainer exampleOneLineEditor.
>
> TxViewContainer editText: 'Philippe Back'.

Thx Sven. I'll try that out.

Phil
>
> Sven

Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Stephan Eggermont-3
In reply to this post by Thierry Goubier
On 04-04-16 16:49, Thierry Goubier wrote:
> Framemaker-like or web-page like? Thierry
Framemaker.

Stephan




Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Igor Stasenko
In reply to this post by Denis Kudriashov


On 4 April 2016 at 17:47, Denis Kudriashov <[hidden email]> wrote:

2016-04-04 16:11 GMT+02:00 Thierry Goubier <[hidden email]>:
It is. Five packages, 1609 + 2647 lines of code (excluding tests and styler).

I think Denis has worked on it (and extended it).

History was that:
At some point I realised that I can't use old TextMorph anymore. For my project I needed flexible editors which allows me implement validation, mask fields, secrete fields and others. It was almost impossible to hack old text morph to support these features. 
I read about Igor project TxText. It included only model at that time which was very similar to my ideas. So I decided to implement editors on top of it. I was try to not touch model itself and only fix bugs. But during development I saw all weakness of model and I start refactoring with idea of active text which announces any changes.
And in same time Igor returned to this project. He saw all problems with model and started refactoring too. But his idea was opposite to my. 

I would not say it opposite. 
You see, you started implementing advanced features, right from the beginning, while we didn't even finished the basic set of features, like simple text input/editing.
The only 'opposite' to your direction was decision to stop thinking upfront how much steroids we can put into model & editor and concentrate on completing a bare bone feature set, so that we can replace morphic text editor with it.  
Adding steroids can wait :)
 
At the end I forked my refactored version of TxText into separate project Twisty. So I think current TxText not includes any my code.


Glad to hear that you did not thrown away your project.


--
Best regards,
Igor Stasenko.
Reply | Threaded
Open this post in threaded view
|

Re: TxText model

Thierry Goubier
In reply to this post by Igor Stasenko


2016-04-04 17:07 GMT+02:00 Igor Stasenko <[hidden email]>:


For now, external objects can't extend below the baseline.

Slightly not like that. An external object are bound to concrete position in text. And layout of a single line are computed based on dimensions of that object, as well as dimensions of other parts of a line. The text flow are not affected by the object in terms that there is no capability to compute wrapping text around it or align it left/right whatever separately from text. It means that basically external object is like a special kind of glyph/icon that uses same layout rules as character glyphs, but just rendered separately. 

I understood as much. I've just seen code that such a "special" glyph can only contribute to text ascent (since, per comment, it is aligned to the baseline). Not very important, just a detail.

 

Position inside spans can be ambiguous: last position of a span and first position of the next span are the same position.

Well, for some operation the are treated as same, for some - don't.
Since there's nothing can be between two positions at the ends of adjacent spans, from standpoint of user they represent same position in text. But from standpoint of model they are different since position are belong to different spans.
Sure thing, there certain pieces added to avoid problems with such ambiguity, so that it don't causing problems on user-level.

Ok.
 
Thierry
1234