7 inclusion of the above copyright notice. This software may not |
7 inclusion of the above copyright notice. This software may not |
8 be provided or otherwise made available to, or used by, any |
8 be provided or otherwise made available to, or used by, any |
9 other person. No title to or ownership of the software is |
9 other person. No title to or ownership of the software is |
10 hereby transferred. |
10 hereby transferred. |
11 " |
11 " |
|
12 |
|
13 'From Smalltalk/X, Version:3.2.1 on 14-oct-1997 at 11:22:55 pm' ! |
12 |
14 |
13 ListView subclass:#TextView |
15 ListView subclass:#TextView |
14 instanceVariableNames:'selectionStartLine selectionStartCol selectionEndLine |
16 instanceVariableNames:'selectionStartLine selectionStartCol selectionEndLine |
15 selectionEndCol clickStartLine clickStartCol clickLine clickCol |
17 selectionEndCol clickStartLine clickStartCol clickLine clickCol |
16 clickCount expandingTop wordStartCol wordStartLine wordEndCol |
18 clickCount expandingTop wordStartCol wordStartLine wordEndCol |
1272 "save the contents into a file named fileName" |
1274 "save the contents into a file named fileName" |
1273 |
1275 |
1274 self withCursor:Cursor write do:[ |
1276 self withCursor:Cursor write do:[ |
1275 |aStream msg| |
1277 |aStream msg| |
1276 |
1278 |
1277 aStream := FileStream newFileNamed:fileName. |
1279 FileStream openErrorSignal catch:[ |
|
1280 aStream := FileStream newFileNamed:fileName. |
|
1281 ]. |
1278 aStream isNil ifTrue:[ |
1282 aStream isNil ifTrue:[ |
1279 msg := resources string:'cannot write file %1 !!' with:fileName. |
1283 msg := resources string:'cannot write file %1 !!' with:fileName. |
1280 self warn:(msg , '\\(' , FileStream lastErrorString , ')' ) withCRs |
1284 self warn:(msg , '\\(' , FileStream lastErrorString , ')' ) withCRs |
1281 ] ifFalse:[ |
1285 ] ifFalse:[ |
1282 self |
1286 self |
1283 fileOutContentsOn:aStream |
1287 fileOutContentsOn:aStream |
1284 compressTabs:true |
1288 compressTabs:true |
1285 encoding:externalEncoding. |
1289 encoding:externalEncoding. |
1286 aStream close. |
1290 aStream close. |
1287 contentsWasSaved := true |
1291 contentsWasSaved := true |
1288 ] |
1292 ] |
1289 ] |
1293 ] |
1290 |
1294 |
1291 "Modified: 5.1.1997 / 02:14:46 / cg" |
1295 "Modified: 13.10.1997 / 12:22:39 / cg" |
1292 ! |
1296 ! |
1293 |
1297 |
1294 search |
1298 search |
1295 "search for a string - show a box to enter searchpattern |
1299 "search for a string - show a box to enter searchpattern |
1296 - currently no regular expressions are handled." |
1300 - currently no regular expressions are handled." |