--- a/CVSSourceCodeManager.st Fri Oct 07 07:01:32 2016 +0200
+++ b/CVSSourceCodeManager.st Fri Oct 14 06:49:26 2016 +0200
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
"
COPYRIGHT (c) 1995 by Claus Gittinger
All Rights Reserved
@@ -1827,7 +1825,7 @@
"/
"/ pretty good - nothing has changed in the meanwhile
"/
- Transcript showCR:'checking in ' , containerFilename , ' ...'
+ Transcript showCR:'CVSSourceCodeManager [info]: checking in ' , containerFilename , ' ...'
] ifFalse:[
| mySource mergedSource |
@@ -1908,7 +1906,7 @@
"/ Transcript showCR:'checkin aborted - (no merge; repository unchanged)'.
"/ ^ false.
"/ ].
- Transcript showCR:'checking in ' , containerFilename , ' (merged other changes) ...'
+ Transcript showCR:'CVSSourceCodeManager [info]: checking in ' , containerFilename , ' (merged other changes) ...'
]
] ifFalse:[
(whatHappened startsWith:'C ') ifTrue:[
@@ -2023,7 +2021,7 @@
].
checkInRepaired ifTrue:[
- Transcript showCR:'checking in ' , containerFilename , ' (manually repaired version) ...'
+ Transcript showCR:'CVSSourceCodeManager [info]: checking in ' , containerFilename , ' (manually repaired version) ...'
] ifFalse:[
'CVSSourceCodeManager [warning]: cannot (for now) checkin; conflicts found' infoPrintCR.
Transcript showCR:'checkin of ' , containerFilename , ' aborted (conflicting changes; repository unchanged)'.
@@ -2420,7 +2418,7 @@
"/
"/ pretty good - nothing has changed in the meanwhile
"/
- Transcript showCR:('checking in %1 (%2)...' bindWith:className with:modulePath).
+ Transcript showCR:('CVSSourceCodeManager [info]: checking in %1 (%2)...' bindWith:className with:modulePath).
] ifFalse:[
|mySource mergedSource |
@@ -2515,7 +2513,7 @@
"/ Transcript showCR:'checkin aborted - (no merge; repository unchanged)'.
"/ ^ false.
"/ ].
- Transcript showCR:('checking in %1 (%2) (merge)...' bindWith:className with:modulePath).
+ Transcript showCR:('CVSSourceCodeManager [info]: checking in %1 (%2) (merge)...' bindWith:className with:modulePath).
]
] ifFalse:[
(whatHappened startsWith:'C ') ifTrue:[
@@ -2650,10 +2648,10 @@
checkInRepaired ifTrue:[
checkInNew ifTrue:[
- Transcript showCR:('checking in %1 (%2) (force)...' bindWith:className with:modulePath).
+ Transcript showCR:('CVSSourceCodeManager [info]: checking in %1 (%2) (force)...' bindWith:className with:modulePath).
] ifFalse:[
conflictResolvedManually := true. "/ checkInRepaired and:[checkInNew not].
- Transcript showCR:('checking in %1 (%2) (manually repaired)...' bindWith:className with:modulePath).
+ Transcript showCR:('CVSSourceCodeManager [info]: checking in %1 (%2) (manually repaired)...' bindWith:className with:modulePath).
].
] ifFalse:[
Transcript showCR:'checkin of ' , className , ' aborted (conflicting changes; repository unchanged)'.
@@ -4741,17 +4739,17 @@
"/ The repair code will be removed at some time in the future...
"/ temporary fix Felix' bad string translation:
- (aString startsWith:'§Header:') ifTrue:[
- (aString endsWith:'Exp §') ifTrue:[
+ (aString startsWith:'§Header:') ifTrue:[
+ (aString endsWith:'Exp §') ifTrue:[
fixedString := '$' , (aString copyFrom:3 to:(aString size - 2)) , '$'.
aClass isNil ifTrue:[
autoFixHolder value ifFalse:[
- Dialog information:'Attention: the CVS version string is corrupted (§-bug). Please fix it manually'.
+ Dialog information:'Attention: the CVS version string is corrupted (§-bug). Please fix it manually'.
]
] ifFalse:[
(autoFixHolder value
- or:[ Dialog confirm:('Attention: the CVS version string is corrupted in "%1" (§-bug). Fix it?' withCRs bindWith:aClass name) ]
+ or:[ Dialog confirm:('Attention: the CVS version string is corrupted in "%1" (§-bug). Fix it?' withCRs bindWith:aClass name) ]
) ifTrue:[
self updateVersionMethodOf:aClass for:fixedString.
].
@@ -4759,7 +4757,7 @@
].
].
- "/ temporary fix Jan's bad Umlaut-removal (which results in Felix's bad § being removed):
+ "/ temporary fix Jan's bad Umlaut-removal (which results in Felix's bad § being removed):
(aString startsWith:'Header: ') ifTrue:[
(aString endsWith:'Exp ') ifTrue:[
fixedString := '$' , aString , '$'.
--- a/HTMLDocGenerator.st Fri Oct 07 07:01:32 2016 +0200
+++ b/HTMLDocGenerator.st Fri Oct 14 06:49:26 2016 +0200
@@ -20,7 +20,7 @@
warnLines hintLines authorLines classProtocolCategories
instanceProtocolCategories generateJavaScriptCallInfo
generateDocumentForOfflineReading showUpButton'
- classVariableNames:''
+ classVariableNames:'CachedKWIC'
poolDictionaries:''
category:'System-Documentation'
!
@@ -204,6 +204,22 @@
"
!
+htmlKWOCList
+ "
+ CachedKWIC := nil
+ "
+ CachedKWIC isNil ifTrue:[
+ CachedKWIC := self generateKWIC.
+ "/ to flush the cached kwic, whenever a class-documentation method is changed
+ Smalltalk addDependent:self class.
+ ].
+ ^ self new htmlKWOCListFor:CachedKWIC
+
+ "
+ HTMLDocGenerator htmlKWOCList
+ "
+!
+
htmlOfflineClassCategoryList
"generate a formatted list of all available class categories as
an HTML string. Each category will be a hyperlink to another
@@ -350,6 +366,47 @@
!HTMLDocGenerator class methodsFor:'document generation-helpers'!
+generateKWIC
+ |fillWords kwic|
+
+ fillWords :=
+ #(
+ 'the' 'a'
+ 'can' 'you'
+ 'to' 'in' 'at' 'of'
+ 'also' 'with' 'without' 'all' 'any' 'how'
+ 'however' 'although' 'always'
+ 'anywhere' 'anyway' 'anything' 'anyone'
+ 'not' 'but'
+ 'am' 'are' 'is' 'be' 'will' 'wont' 'won''t' 'do' 'don''t'
+ 'my' 'their' 'your' 'its'
+ 'one' 'two' 'three'
+ 'etc' 'for'
+ 'use' 'this' 'that' 'which' 'what' 'why'
+ ).
+
+ kwic := KeywordInContextIndexBuilder new.
+ kwic excluded:fillWords.
+ kwic separatorAlgorithm:[:line | line asCollectionOfSubstringsSeparatedByAny:' ^~=@.:,;-+*/()[]|{}#"''<>',Character cr].
+ kwic exclusionFilter:[:word |
+ word size == 1
+ or:[ word conform:#isDigit ]].
+
+ Smalltalk allClassesDo:[:eachClass |
+ |doc|
+
+ doc := eachClass commentOrDocumentationString.
+ doc notEmptyOrNil ifTrue:[
+ kwic addLine:doc reference:eachClass ignoreCase:true.
+ ].
+ ].
+ ^ kwic
+
+ "
+ self generateKWIC
+ "
+!
+
htmlForMethod:aMethod
|who sel partStream args argStream methodSpecLine|
@@ -2223,6 +2280,78 @@
"Modified: / 10-11-2006 / 17:11:30 / cg"
!
+htmlKWOCListFor:aKWIC
+ "generate a formatted list of all keywords in context from class documentation
+ as an HTML string.
+ Each keword will be a hyperlinked to another
+ autogenerated page, containing the classes documentation.
+ The generated page is supposed to be given to an HTML reader
+ with home being set to ../doc/online/xxx/classDoc
+ (i.e. the images are to be found one-up in the doc hierarchy)"
+
+ |prevWord caseMapping|
+
+ outStream := '' writeStream.
+
+ self generateHTMLHeadWithTitle:'Keyword Index:'.
+ self generateBODYStart.
+ self generateUpArrowButtonForTop.
+ self generateHorizontalLine.
+
+ self generateH1:'Keywords:'.
+ outStream nextPutLine:'<dl>'.
+ prevWord := nil.
+
+ caseMapping := Dictionary new.
+ aKWIC entriesDo:[:word :left :right :class|
+ |lcWord wordAlready|
+
+ lcWord := word asLowercase.
+ lcWord ~= word ifTrue:[
+ wordAlready := caseMapping at:lcWord ifAbsent:[nil].
+ wordAlready isNil ifTrue:[
+ caseMapping at:lcWord put:word
+ ].
+ ].
+ ].
+
+ aKWIC matchSorter:[:a :b | a value name < b value name].
+
+ aKWIC entriesDo:[:word :left :right :class|
+ |ref lcWord ctx|
+
+ ctx := (HTMLUtilities escapeCharacterEntities:(left contractAtBeginningTo:25))
+ ,' <b>',(HTMLUtilities escapeCharacterEntities:word),'</b> '
+ ,(HTMLUtilities escapeCharacterEntities:(right contractAtEndTo:25)).
+
+ lcWord := word asLowercase.
+ lcWord ~= prevWord ifTrue:[
+ prevWord notNil ifTrue:[
+ outStream nextPutLine:'</ul></dd>'.
+ ].
+ "/ outStream nextPutLine:'<dt>',(HTMLUtilities escapeCharacterEntities:(caseMapping at:lcWord ifAbsent:[word])),'</dt>'.
+ outStream nextPutLine:'<dt>',(HTMLUtilities escapeCharacterEntities:word),'</dt>'.
+ outStream nextPutLine:'<dd><ul><li>'.
+ self generateClassDocReferenceFor:class name.
+ outStream nextPutAll:'<tab indent=300>'.
+ outStream nextPutLine:ctx.
+ outStream nextPutLine:'</li>'.
+ prevWord := lcWord.
+ ] ifFalse:[
+ outStream nextPutLine:'</li><li>'.
+ self generateClassDocReferenceFor:class name.
+ outStream nextPutAll:'<tab indent=300>'.
+ outStream nextPutLine:ctx.
+ outStream nextPutLine:'</li>'.
+ ].
+ ].
+ outStream nextPutLine:'</ul></dd>'.
+ outStream nextPutLine:'</dl>'.
+
+ self generateBODYandHTMLEnd.
+ ^ outStream contents
+!
+
htmlPackageDocOf:packageID
|classes|
--- a/HistoryManager.st Fri Oct 07 07:01:32 2016 +0200
+++ b/HistoryManager.st Fri Oct 14 06:49:26 2016 +0200
@@ -60,7 +60,7 @@
on change, intercepts them and appends a historyLine to the methods
code.
- The HistoryManager can be turned on/off from aprivate.rc script,
+ The HistoryManager can be turned on/off from a private.rc script,
or via the Launcher menu.
The method's history line is filtered, to only contain one
--- a/ProjectProblem.st Fri Oct 07 07:01:32 2016 +0200
+++ b/ProjectProblem.st Fri Oct 14 06:49:26 2016 +0200
@@ -248,7 +248,7 @@
documentation
"
- I represent a problem as detect by the project consistency checker,
+ I represent a problem as detected by the project consistency checker,
which is optionally executed before committing a package to a repository.
Typically, I find inconsistencies, uncompilable methods or missing prerequisites,
which might lead to trouble when the package is later to be compiled to a dll via stc.