You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by Greg Brown <gk...@mac.com> on 2010/09/10 03:42:31 UTC

TextArea/RichTextArea

Hi all,

I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.

I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.

The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.

I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).

We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.

Let me know what you think.

G


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
> What specific bugs did you find? As far as I know, I've worked them all out now.

I had some trouble getting bulleted lists to work. 

>> Yes, we can do this. But I am genuinely concerned about the stability and maintenance of RichTextArea - not because the work that Noel has done recently, but because I think the original design (which I am responsible for) is too heavy. 
> Maybe you haven't seen too many other examples of editor code, but having spent some time in the bowels of other Java
> text editing components, I can safely say that your design is pretty decent :-)

I have seen some of the Swing code, and yes - I agree that this design is a bit cleaner.  :-)  But, having written and re-written Pivot's text components several times now, I know we can do even better.

> I didn't notice that it was that heavily dependent on the concept of paragraphs.

It is currently based too heavily on carriage returns. These are necessary in plain text editing, since the delimiters are necessary to identify the paragraphs that comprise the "elements" of the "document". However, RichTextArea doesn't really need this concept since it already has a set of DOM classes. 

I suspect that an editing model based on an "active" or "selected" node would work better than the current "selection index/length" model (which works better for plain text editing), and would allow us to get rid of all of the character-based offset management overhead. Basically, we'd use the character model for TextArea, and the DOM model for RichTextArea/TextPane.

> If you think of it as being based
> around the concept of laying out rectangular pixel chunks in a left-to-right, top-to-bottom way, then it (mentally)
> works pretty well.

Yes, I agree that this works well. This is one of the pieces I think we should keep.  :-)

G



Re: TextArea/RichTextArea

Posted by Noel Grandin <no...@gmail.com>.
 Greg Brown wrote:
> I noticed a few bugs, though Noel may be planning to work these out before we release 2.0. Also, we'd ideally want to
> include a RichTextToolbar component along with RichTextArea, since most developers will want to use the two together. 
What specific bugs did you find? As far as I know, I've worked them all out now.
Yeah, I was wondering about the toolbar thing, that's why I've kept adding features to the example code. I wasn't too
sure about the appropriate level of packaging it up as a component to be re-used, so I didn't try to make the example a
fully-fledged Pivot component.

> Yes, we can do this. But I am genuinely concerned about the stability and maintenance of RichTextArea - not because the work that Noel has done recently, but because I think the original design (which I am responsible for) is too heavy. 
Maybe you haven't seen too many other examples of editor code, but having spent some time in the bowels of other Java
text editing components, I can safely say that your design is pretty decent :-)

I didn't notice that it was that heavily dependent on the concept of paragraphs. If you think of it as being based
around the concept of laying out rectangular pixel chunks in a left-to-right, top-to-bottom way, then it (mentally)
works pretty well.
The layout()/paint() logic is a bit hairy and could do with some cleanup, but it's not a major problem.

-- Noel

Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
Just a little more background on this - to me, it is as much a question about process as it is about design. Like most open-source projects, Pivot is a volunteer-driven effort with limited resources. In order to be successful, we need to map our development process to these constraints. That's one of the reasons that an iterative approach works well. It allows us to make progress in more manageable chunks.

For example, at some point in the future, Noel may no longer be interested or available to work on RichTextArea. It should be possible for someone else to easily step in and understand how the code works, so that we can continue to fix bugs and add new features. I wrote the original code for that component, so I know that it works, but I also know how complex it is, and I know we can do better.

If we take a step back and refactor out the stuff that we don't strictly need right now, we will:

a) Have a useful, more stable layout container in a shorter timeframe

b) Have a cleaner codebase upon which to build new features

c) Better position ourselves for longer-term success

G


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
>> The existing (rich) TextArea class can certainly be used for this purpose,
>> but it currently has a lot of baggage since it supports editing. A pure
>> "text pane" wouldn't need such support, so it would significantly simplify
>> the codebase if we were to eliminate it.
> 
> Perhaps I am misunderstanding something (or very possibly confusing the
> names of existing & future/proposed components), but it seems a little odd
> to describe the editing capabilities of a component designed for editing to
> be 'baggage'.

It was originally designed for editing, but the implementation is quite complex. This complexity is the main reason I created the new plain TextArea component, which is designed specifically to be easier to understand and maintain.

> The 'TextPane' could then subclass or delegate to the non-editable version.

In what I am proposing, TextPane would be the non-editable version (and also possibly the editable version - see below).

>> I think there may be a lot more long-term value in a "TextPane" class than a
>> "RichTextArea" component. It would also be a lot easier to maintain (which
>> is a very valid concern in a volunteer-driven effort like Pivot).
>> 
> 
> I only took a cursory look at Noel's rich text demo when he committed it,
> but it seemed to be working OK. Assuming the component is functional, I
> don't see that it would require any unusual level of maintenance.

I noticed a few bugs, though Noel may be planning to work these out before we release 2.0. Also, we'd ideally want to include a RichTextToolbar component along with RichTextArea, since most developers will want to use the two together.

> We can
> always document any limitations it might have, and describe it as a
> relatively new and lightly tested component if required.

Yes, we can do this. But I am genuinely concerned about the stability and maintenance of RichTextArea - not because the work that Noel has done recently, but because I think the original design (which I am responsible for) is too heavy. The current editing features are based heavily on the concept of paragraph separators. This is required in a plain text editor, but may bot be strictly necessary for rich text editing. It just adds overhead and complexity (i.e. "baggage"). I'd like to eliminate this baggage and keep the good parts (the layout). Later, we can then think about how editing might best be implemented in a rich text editor, not a rich text editor that is trying to do double-duty as a plain text editor as well. 

I'd be much more comfortable renaming this component TextPane and positioning it as a layout container for Pivot 2.0. That would allow us to pull out all editing related features, including node offset and range maintenance, keyboard handling, etc. It will really thin out the component, and we can focus on making it stable. I suspect that once we have done that, we may see an easier way to re-integrate the editing capabilities.

I think this represents a better long-term strategy since it allows us to release a stable and very useful component in a shorter timeframe, and then build on it later (add editing, add rich text toolbar, etc.). This approach is consistent with agile development concepts, which seem to work well on OSS projects.

It is also why I think the name "TextPane" works well. It makes sense for a non-editable initial version but also works when/if we revisit editing (as does "TextPaneToolbar").

G


Re: TextArea/RichTextArea

Posted by Chris Bartlett <cb...@gmail.com>.
On 10 September 2010 08:42, Greg Brown <gk...@mac.com> wrote:

>
> The existing (rich) TextArea class can certainly be used for this purpose,
> but it currently has a lot of baggage since it supports editing. A pure
> "text pane" wouldn't need such support, so it would significantly simplify
> the codebase if we were to eliminate it.
>

Perhaps I am misunderstanding something (or very possibly confusing the
names of existing & future/proposed components), but it seems a little odd
to describe the editing capabilities of a component designed for editing to
be 'baggage'.

If it is baggage from the perspective of another component that wishes to
build upon the first, but doesn't need that functionality, then couldn't
there be a case for refactoring the existing component into non-editable
base class and an editable subclass?

The 'TextPane' could then subclass or delegate to the non-editable version.


I think there may be a lot more long-term value in a "TextPane" class than a
> "RichTextArea" component. It would also be a lot easier to maintain (which
> is a very valid concern in a volunteer-driven effort like Pivot).
>

I only took a cursory look at Noel's rich text demo when he committed it,
but it seemed to be working OK. Assuming the component is functional, I
don't see that it would require any unusual level of maintenance. We can
always document any limitations it might have, and describe it as a
relatively new and lightly tested component if required.

Obviously we wouldn't want to keep obsolete Components within the Pivot code
base, but even playing devil's advocate and assuming that there are issues
with the existing Component, wouldn't those issues would only affect users
who choose to use it?



> We don't necessarily need to decide right now, but I'm thinking that
> "TextPane" might be a more appropriate name for this component either way.
> It also has a bit more parity with the "org.apache.pivot.wtk.text" package,
> and the view classes, which currently live in org.apache.pivot.wtk.skin,
> could be moved to org.apache.pivot.wtk.skin.text.
>
> Let me know what you think.
>
> G
>
> I can't really comment on the naming until I understand what the components
there will be and their differing functionalities.

Chris

Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
I actually like TextPane:

1) As I mentioned in the other email, it doesn't imply editability but can also support it in the future.

2) The "Pane" suffix makes it clear that it is a container and therefore used for layout.

3) Since its primary purpose would be to support text-like layouts (where the content flows in paragraphs, like text), the "Text" prefix is also appropriate.

4) It is tightly integrated with the classes in the "org.apache.pivot.wtk.text" package, so it has naming consistency.

I could also see an argument for "DocumentPane" or "TextLayoutPane", but I think "TextPane" works better.

G

On Sep 10, 2010, at 3:35 AM, Noel Grandin wrote:

> 
> Obviously, I'm a little biased, because I did the rich text area work :-), but I think there is a lot of value in
> continuing to support the current rich text editor component.
> 
> However, I really like what you are proposing. It sounds a lot like the Eclipse Forms project,
> http://www.eclipse.org/articles/Article-Forms/article.html
> which was designed to make text/form/html type layout designs much easier to achieve.
> 
> I suggest we rename TextArea to RichTextArea or StyledTextArea.
> 
> I don't have an really good suggestions for the new layout component.
> FormPane would conflict with our current Form class,
> TextPane sounds too much like something text-specific,
> FormLayoutPane?
> TextLayoutPane?
> PagePane?
> Just throwing ideas out there.
> 
> 
> Greg Brown wrote:
>> Hi all,
>> 
>> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
>> 
>> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
>> 
>> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
>> 
>> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
>> 
>> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
>> 
>> Let me know what you think.
>> 
>> G
>> 
> 


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
I actually like TextPane:

1) As I mentioned in the other email, it doesn't imply editability but can also support it in the future.

2) The "Pane" suffix makes it clear that it is a container and therefore used for layout.

3) Since its primary purpose would be to support text-like layouts (where the content flows in paragraphs, like text), the "Text" prefix is also appropriate.

4) It is tightly integrated with the classes in the "org.apache.pivot.wtk.text" package, so it has naming consistency.

I could also see an argument for "DocumentPane" or "TextLayoutPane", but I think "TextPane" works better.

G

On Sep 10, 2010, at 3:35 AM, Noel Grandin wrote:

> 
> Obviously, I'm a little biased, because I did the rich text area work :-), but I think there is a lot of value in
> continuing to support the current rich text editor component.
> 
> However, I really like what you are proposing. It sounds a lot like the Eclipse Forms project,
> http://www.eclipse.org/articles/Article-Forms/article.html
> which was designed to make text/form/html type layout designs much easier to achieve.
> 
> I suggest we rename TextArea to RichTextArea or StyledTextArea.
> 
> I don't have an really good suggestions for the new layout component.
> FormPane would conflict with our current Form class,
> TextPane sounds too much like something text-specific,
> FormLayoutPane?
> TextLayoutPane?
> PagePane?
> Just throwing ideas out there.
> 
> 
> Greg Brown wrote:
>> Hi all,
>> 
>> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
>> 
>> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
>> 
>> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
>> 
>> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
>> 
>> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
>> 
>> Let me know what you think.
>> 
>> G
>> 
> 


Re: TextArea/RichTextArea

Posted by Noel Grandin <no...@gmail.com>.
Obviously, I'm a little biased, because I did the rich text area work :-), but I think there is a lot of value in
continuing to support the current rich text editor component.

However, I really like what you are proposing. It sounds a lot like the Eclipse Forms project,
http://www.eclipse.org/articles/Article-Forms/article.html
which was designed to make text/form/html type layout designs much easier to achieve.

I suggest we rename TextArea to RichTextArea or StyledTextArea.

I don't have an really good suggestions for the new layout component.
FormPane would conflict with our current Form class,
TextPane sounds too much like something text-specific,
FormLayoutPane?
TextLayoutPane?
PagePane?
Just throwing ideas out there.


Greg Brown wrote:
> Hi all,
>
> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
>
> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
>
> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
>
> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
>
> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
>
> Let me know what you think.
>
> G
>


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
> Do you have time to quickly summarize what text based components &
> containers you envision for Pivot 2.0?

Pivot 2.0 will include the same set of text components as earlier releases:

Label (read-only, optionally wrapping, unstyled label)
TextInput (single-line unstyled text field)
TextArea (multi-line unstyled text area) (a new version in 2.0 replaces the existing TextArea component)

TextPane would be an additional component (based on the pre-2.0 TextArea) that supports text-based layout similar to HTML. Not sure what timeframe would be appropriate for this component, but I imagine that we could probably get a read-only version ready for 2.0. Then we could potentially consider re-integrating editability into this component in a later release.

Does that help?




Re: TextArea/RichTextArea

Posted by Chris Bartlett <cb...@gmail.com>.
Greg,

Do you have time to quickly summarize what text based components &
containers you envision for Pivot 2.0?

Names are not so important here, I am just trying to understand the features
that would be available.
I suppose the most important points are whether they would be editable or
not, components or containers, and support rich or plain text.

For instance

Label
- As per Pivot 1.5.1
- Non-editable single line, plain text control (component)

TextInput
- As per Pivot 1.5.1
- User editable single line, plain text control (component)

...


All the points you have made seem reasonable, especially given your in depth
knowledge and previous work on these components.
I'm all for starting simple and adding functionality (and often complexity)
as and when the need arises.

My immediate needs would be met with an editable plain text component, but
would probably find uses for a rich text equivalent if it existed.

Chris


On 11 September 2010 01:10, Greg Brown <gk...@mac.com> wrote:

> > I think it depends on a few factors such as the actual code complexity
>
> As I mentioned earlier, the code is simply more complex than it needs to be
> at the moment. Removing what I would consider to be non-essential code from
> the existing rich TextArea component and related DOM classes will streamline
> the codebase (i.e. reduce the overall complexity) and will most likely allow
> us to create a more efficient solution for editing in the future, if we so
> choose.
>
> > Its not clear it's a high-priority area for pivot as a project.
>
>
> I agree that it may not be the highest priority right now. However, that
> doesn't make the concept any less valuable. At least one user has already
> requested such a feature, and I imagine that many developers might benefit
> from it.
>
>
>

Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
> I think it depends on a few factors such as the actual code complexity

As I mentioned earlier, the code is simply more complex than it needs to be at the moment. Removing what I would consider to be non-essential code from the existing rich TextArea component and related DOM classes will streamline the codebase (i.e. reduce the overall complexity) and will most likely allow us to create a more efficient solution for editing in the future, if we so choose.

> Its not clear it's a high-priority area for pivot as a project.


I agree that it may not be the highest priority right now. However, that doesn't make the concept any less valuable. At least one user has already requested such a feature, and I imagine that many developers might benefit from it.



Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
> I think it depends on a few factors such as the actual code complexity

As I mentioned earlier, the code is simply more complex than it needs to be at the moment. Removing what I would consider to be non-essential code from the existing rich TextArea component and related DOM classes will streamline the codebase (i.e. reduce the overall complexity) and will most likely allow us to create a more efficient solution for editing in the future, if we so choose.

> Its not clear it's a high-priority area for pivot as a project.


I agree that it may not be the highest priority right now. However, that doesn't make the concept any less valuable. At least one user has already requested such a feature, and I imagine that many developers might benefit from it.



RE: TextArea/RichTextArea

Posted by aappddeevv <aa...@verizon.net>.
I think it depends on a few factors such as the actual code complexity,
memory footprint and other benefits and capabilities for styled text etc.
Its not clear it's a high-priority area for pivot as a project.

I built a read-only text area based on the jse's line breaking support
classes, multiple styles and a tiny doc model (and modified the serializer
so that free text can be provided between element tags). The code is smaller
than the TextArea editing code but not dramatically, and the footprint can
be smaller, but its not clear that supporting it would be any less easy than
the full editing version in the pivot library.



-----Original Message-----
From: Greg Brown [mailto:gkbrown@mac.com] 
Sent: Thursday, September 09, 2010 10:10 PM
To: Pivot Dev
Cc: Pivot User
Subject: Re: TextArea/RichTextArea

By the way, this suggestion doesn't invalidate any of the (extensive) work
that Noel has done recently with TextArea. In fact, it wouldn't be possible
without it. I'm just wondering if a supporting read-only text pane might be
a better long-term strategy than supporting rich text authoring...


On Sep 9, 2010, at 9:42 PM, Greg Brown wrote:

> Hi all,
> 
> I'm about ready to check in final support for the new TextArea. There are
still a few bugs to work out, but it is mostly functional.
> 
> I'd like to raise the question again of what to call the new "rich text
area". I'm still pretty excited about the concept of a "TextPane" component
- this would be a container whose primary purpose is to support text-based
layouts that aren't easily achievable (or even possible) using some of our
other layout containers. For example, designers of complex text-based forms
could really benefit from such a component.
> 
> The existing (rich) TextArea class can certainly be used for this purpose,
but it currently has a lot of baggage since it supports editing. A pure
"text pane" wouldn't need such support, so it would significantly simplify
the codebase if we were to eliminate it.
> 
> I think there may be a lot more long-term value in a "TextPane" class than
a "RichTextArea" component. It would also be a lot easier to maintain (which
is a very valid concern in a volunteer-driven effort like Pivot).
> 
> We don't necessarily need to decide right now, but I'm thinking that
"TextPane" might be a more appropriate name for this component either way.
It also has a bit more parity with the "org.apache.pivot.wtk.text" package,
and the view classes, which currently live in org.apache.pivot.wtk.skin,
could be moved to org.apache.pivot.wtk.skin.text.
> 
> Let me know what you think.
> 
> G
> 


RE: TextArea/RichTextArea

Posted by aappddeevv <aa...@verizon.net>.
I think it depends on a few factors such as the actual code complexity,
memory footprint and other benefits and capabilities for styled text etc.
Its not clear it's a high-priority area for pivot as a project.

I built a read-only text area based on the jse's line breaking support
classes, multiple styles and a tiny doc model (and modified the serializer
so that free text can be provided between element tags). The code is smaller
than the TextArea editing code but not dramatically, and the footprint can
be smaller, but its not clear that supporting it would be any less easy than
the full editing version in the pivot library.



-----Original Message-----
From: Greg Brown [mailto:gkbrown@mac.com] 
Sent: Thursday, September 09, 2010 10:10 PM
To: Pivot Dev
Cc: Pivot User
Subject: Re: TextArea/RichTextArea

By the way, this suggestion doesn't invalidate any of the (extensive) work
that Noel has done recently with TextArea. In fact, it wouldn't be possible
without it. I'm just wondering if a supporting read-only text pane might be
a better long-term strategy than supporting rich text authoring...


On Sep 9, 2010, at 9:42 PM, Greg Brown wrote:

> Hi all,
> 
> I'm about ready to check in final support for the new TextArea. There are
still a few bugs to work out, but it is mostly functional.
> 
> I'd like to raise the question again of what to call the new "rich text
area". I'm still pretty excited about the concept of a "TextPane" component
- this would be a container whose primary purpose is to support text-based
layouts that aren't easily achievable (or even possible) using some of our
other layout containers. For example, designers of complex text-based forms
could really benefit from such a component.
> 
> The existing (rich) TextArea class can certainly be used for this purpose,
but it currently has a lot of baggage since it supports editing. A pure
"text pane" wouldn't need such support, so it would significantly simplify
the codebase if we were to eliminate it.
> 
> I think there may be a lot more long-term value in a "TextPane" class than
a "RichTextArea" component. It would also be a lot easier to maintain (which
is a very valid concern in a volunteer-driven effort like Pivot).
> 
> We don't necessarily need to decide right now, but I'm thinking that
"TextPane" might be a more appropriate name for this component either way.
It also has a bit more parity with the "org.apache.pivot.wtk.text" package,
and the view classes, which currently live in org.apache.pivot.wtk.skin,
could be moved to org.apache.pivot.wtk.skin.text.
> 
> Let me know what you think.
> 
> G
> 


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
By the way, this suggestion doesn't invalidate any of the (extensive) work that Noel has done recently with TextArea. In fact, it wouldn't be possible without it. I'm just wondering if a supporting read-only text pane might be a better long-term strategy than supporting rich text authoring...


On Sep 9, 2010, at 9:42 PM, Greg Brown wrote:

> Hi all,
> 
> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
> 
> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
> 
> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
> 
> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
> 
> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
> 
> Let me know what you think.
> 
> G
> 


Re: TextArea/RichTextArea

Posted by Noel Grandin <no...@gmail.com>.
Obviously, I'm a little biased, because I did the rich text area work :-), but I think there is a lot of value in
continuing to support the current rich text editor component.

However, I really like what you are proposing. It sounds a lot like the Eclipse Forms project,
http://www.eclipse.org/articles/Article-Forms/article.html
which was designed to make text/form/html type layout designs much easier to achieve.

I suggest we rename TextArea to RichTextArea or StyledTextArea.

I don't have an really good suggestions for the new layout component.
FormPane would conflict with our current Form class,
TextPane sounds too much like something text-specific,
FormLayoutPane?
TextLayoutPane?
PagePane?
Just throwing ideas out there.


Greg Brown wrote:
> Hi all,
>
> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
>
> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
>
> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
>
> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
>
> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
>
> Let me know what you think.
>
> G
>


Re: TextArea/RichTextArea

Posted by Greg Brown <gk...@mac.com>.
By the way, this suggestion doesn't invalidate any of the (extensive) work that Noel has done recently with TextArea. In fact, it wouldn't be possible without it. I'm just wondering if a supporting read-only text pane might be a better long-term strategy than supporting rich text authoring...


On Sep 9, 2010, at 9:42 PM, Greg Brown wrote:

> Hi all,
> 
> I'm about ready to check in final support for the new TextArea. There are still a few bugs to work out, but it is mostly functional.
> 
> I'd like to raise the question again of what to call the new "rich text area". I'm still pretty excited about the concept of a "TextPane" component - this would be a container whose primary purpose is to support text-based layouts that aren't easily achievable (or even possible) using some of our other layout containers. For example, designers of complex text-based forms could really benefit from such a component.
> 
> The existing (rich) TextArea class can certainly be used for this purpose, but it currently has a lot of baggage since it supports editing. A pure "text pane" wouldn't need such support, so it would significantly simplify the codebase if we were to eliminate it.
> 
> I think there may be a lot more long-term value in a "TextPane" class than a "RichTextArea" component. It would also be a lot easier to maintain (which is a very valid concern in a volunteer-driven effort like Pivot).
> 
> We don't necessarily need to decide right now, but I'm thinking that "TextPane" might be a more appropriate name for this component either way. It also has a bit more parity with the "org.apache.pivot.wtk.text" package, and the view classes, which currently live in org.apache.pivot.wtk.skin, could be moved to org.apache.pivot.wtk.skin.text.
> 
> Let me know what you think.
> 
> G
>