Anonymous | Login | 03-04-2021 15:15 UTC |
Main | My View | View Issues | Change Log | Docs |
Viewing Issue Simple Details [ Jump to Notes ] | [ View Advanced ] [ Issue History ] [ Print ] | |||||||||||
ID | Category | Severity | Reproducibility | Date Submitted | Last Update | |||||||
0007563 | [Squeak] Documentation | major | always | 09-12-10 02:37 | 09-12-10 21:24 | |||||||
Reporter | casey | View Status | public | |||||||||
Assigned To | casey | |||||||||||
Priority | high | Resolution | open | |||||||||
Status | assigned | Product Version | trunk | |||||||||
Summary | 0007563: TextStream needs a class comment | |||||||||||
Description |
The following comment is useless: "A TextStream is xxxxxxxxx. Instance Variables " |
|||||||||||
Additional Information | ||||||||||||
Attached Files | ||||||||||||
|
![]() |
|
(0013876 - 1646 - 2762 - 2876 - 2876 - 2876 - 2876) hirzel 09-12-10 21:24 |
Source: http://wiki.squeak.org/squeak/29 [^] The following example shows how to use class TextStream. It was posted to the Squeak list by Boris Gaertner on 5-Jan-03. | ts | ts := TextStream on: (Text new: 100). ts nextPutAll: 'Class '; withAttribute: TextEmphasis bold do: [ts nextPutAll: 'TextStream']; cr. ts nextPutAll: 'This class is used to create '; withAttributes: (Set with: TextEmphasis bold with: TextEmphasis underlined) do: [ts nextPutAll: 'styled text.']; cr; withAttribute: TextEmphasis italic do: [ts nextPutAll: 'Styled text']; withAttribute: TextEmphasis normal do: [ts nextPutAll: ' has display properties like ']; withAttribute: TextEmphasis bold do: [ts nextPutAll: 'bold ']; withAttribute: TextEmphasis italic do: [ts nextPutAll: 'italic ']; withAttribute: TextEmphasis struckOut do: [ts nextPutAll: 'struck out ']; cr. (Workspace new contents: ts contents) openLabel: 'TextStreams are powerful' -------------- Another example was posted by Boris Gaertner 5-Jul-03 Create a text with a hyperlink in it: | ts | ts := TextStream on: (Text new). ts nextPutAll: 'Squeak is a beautiful language. Look at '. ts withAttribute: (TextURL new url: 'http:\\www.squeak.org') do: [ ts nextPutAll: 'http:\\www.squeak.org']. ts nextPutAll: ' to learn more about it.'. (Workspace new contents: ts contents) openLabel: 'Here is your Hyperlink:' ---------------- To do: check if the examples still work and if not adapt them. |
Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
34 total queries executed. 29 unique queries executed. |