[Skip to Body]
Primary:
[Front Door]
[Current]
[Glance]
-
[Honesty]
[On Teaching and Learning]
Groupings:
[EBoards]
[Examples]
[Exams]
[Handouts]
[Homework]
[Labs]
[Outlines]
[Readings]
[Reference]
Misc:
[SamR]
[Java 1.5 API]
[Espresso]
[TAO of Java]
[CS152 2004F]
Back to Interfaces and Polymorphism. On to Reuse through Inheritance.
Held: Wednesday, March 2, 2005
Summary: Today we ground our understanding of the text composition classes in some simple laboratory exercises.
Related Pages:
Overview:
TextLine implement TextBlock
atWidth to TextLine
VerticallyCompose
HorizontallyCompose
TestText)
SimpleTextBlock, since
the VerticallyCompose can do it.
rebelsky directory in your CS152 directory
text directory in your rebelsky directory
HorizontallyCompose.java to that directory.
TestText.java to that directory.
HorizontallyCompose doesn't work correctly if the thing at the left has fewer lines than the thing at the right. Fix!
Center, whose constructor takes two parameters: the textblock to center and a desired width.
Back to Interfaces and Polymorphism. On to Reuse through Inheritance.
[Skip to Body]
Primary:
[Front Door]
[Current]
[Glance]
-
[Honesty]
[On Teaching and Learning]
Groupings:
[EBoards]
[Examples]
[Exams]
[Handouts]
[Homework]
[Labs]
[Outlines]
[Readings]
[Reference]
Misc:
[SamR]
[Java 1.5 API]
[Espresso]
[TAO of Java]
[CS152 2004F]
Disclaimer:
I usually create these pages on the fly
, which means that I rarely
proofread them and they may contain bad grammar and incorrect details.
It also means that I tend to update them regularly (see the history for
more details). Feel free to contact me with any suggestions for changes.
This document was generated by
Siteweaver on Wed May 11 10:55:58 2005.
The source to the document was last modified on Mon Jan 24 10:17:07 2005.
This document may be found at http://www.cs.grinnell.edu/~rebelsky/Courses/CS152/2005S/Outlines/outline.23.html.
You may wish to
validate this document's HTML
;
;
Check with Bobby