[brailleblaster] Re: "Views" that aren't really Views

  • From: Chris von See <chris@xxxxxxxxxxxxx>
  • To: brailleblaster@xxxxxxxxxxxxx
  • Date: Sat, 11 Jun 2011 17:29:34 -0700

You can keep the backing data store synchronized with the data in both the 
braille and text view using the methods in the extended modify listener. Both 
views will probably need to share an undo/redo stack in order to ensure the 
integrity of the data.

Chris
-- 
Sent from my Android phone.

Susan Jolly <easjolly@xxxxxxxxxxxxx> wrote:

The StyledText widget does not by default present a View of an underlying 
document in the MVC sense. It works with a physical copy of the text of the 
underlying document that it has obtained via its setText method.

If you really want a proper MVC View, then, as I tried to make clear 
yesterday, you need to define your own content model (which has to satisfy 
the StyledTextContent interface) and use the StyledText setContent method to 
tell the widget to use your content model rather than its default.

There are probably more sophisticated ways of doing this with JFace since I 
think that Eclipse itself uses a true MVC paradigm.

Susan 


Other related posts: