Squeak Class Documentation category index | class index  
 
CodeHolder
  category: Kernel-ST80 Remnants
  superclass: StringHolder
  subclasses: Browser ChangeList MethodHolder ChangeSorter Debugger

An ancestor class for all models which can show code. Eventually, much of the code that currently resides in StringHolder which only applies to code-holding StringHolders might get moved down here.

instance methods
  annotation
  addOptionalAnnotationsTo:at:plus:
addPriorVersionsCountForSelector:ofClass:to:
annotation
annotationForSelector:ofClass:
annotationPaneMenu:shifted:
annotationRequests
annotationSeparator
defaultAnnotationPaneHeight
defaultButtonPaneHeight

  categories
  categoryOfCurrentMethod
changeCategory
methodCategoryChanged
selectedMessageCategoryName

  categories & search pane
  listPaneWithSelector:
newSearchPane
searchPane
textPaneWithSelector:

  commands
  abbreviatedWordingFor:
adoptMessageInCurrentChangeset
browseImplementors
browseSenders
copyUpOrCopyDown
makeSampleInstance
offerMenu
offerShiftedClassListMenu
offerUnshiftedClassListMenu
removeClass
shiftedYellowButtonActivity
showUnreferencedClassVars
showUnreferencedInstVars
spawn:
spawnFullProtocol
spawnHierarchy
spawnProtocol
spawnToClass:
spawnToCollidingClass:
unshiftedYellowButtonActivity

  construction
  addLowerPanesTo:at:with:
buildClassBrowserEditString:
buildMorphicCodePaneWith:

  contents
  commentContents
contents
contentsChanged
contentsSymbol
contentsSymbol:

  controls
  addOptionalButtonsTo:at:plus:
buttonWithSelector:
codePaneProvenanceButton
codePaneProvenanceString
contentsSymbolQuints
decorateButtons
decorateForInheritance
inheritanceButton
optionalButtonPairs
optionalButtonRow
sourceAndDiffsQuintsOnly

  diffs
  defaultDiffsSymbol
diffButton
diffFromPriorSourceFor:
prettyDiffButton
regularDiffButton
restoreTextualCodingPane
showDiffs
showDiffs:
showPrettyDiffs:
showRegularDiffs:
showingAnyKindOfDiffs
showingDiffsString
showingPrettyDiffs
showingPrettyDiffsString
showingRegularDiffs
showingRegularDiffsString
toggleColorPrint
toggleDiff
toggleDiffing
togglePlainSource
togglePrettyDiffing
togglePrettyPrint
toggleRegularDiffing
wantsDiffFeedback

  message category functions
  canShowMultipleMessageCategories

  message list
  decompiledSourceIntoContents
selectedBytecodes
selectedMessage
sourceStringPrettifiedAndDiffed
validateMessageSource:forSelector:

  message list menu
  messageListKey:from:

  misc
  getSelectorAndSendQuery:to:
getSelectorAndSendQuery:to:with:
isThereAnOverride
menuButton
modelWakeUpIn:
okayToAccept
priorSourceOrNil
refreshAnnotation
refusesToAcceptCode
releaseCachedState
sampleInstanceOfSelectedClass
sendQuery:to:
setClassAndSelectorIn:
suggestCategoryToSpawnedBrowser:
useSelector:orGetSelectorAndSendQuery:to:

  self-updating
  didCodeChangeElsewhere
stepIn:
updateCodePaneIfNeeded
updateListsAndCodeIn:
wantsStepsIn:

  tiles
  addModelItemsToWindowMenu:
installTextualCodingPane
installTilesForSelection
showTiles:
showingTiles
showingTilesString
tilesToggleButton
toggleShowingTiles

  what to show
  addContentsTogglesTo:
colorPrintString
offerWhatToShowMenu
prettyPrintString
setContentsToForceRefetch
showAltSyntax:
showByteCodes:
showComment
showDecompile:
showDocumentation:
showingAltSyntax
showingAltSyntaxString
showingByteCodes
showingByteCodesString
showingColorPrint
showingDecompile
showingDecompileString
showingDocumentation
showingDocumentationString
showingPlainSource
showingPlainSourceString
showingPrettyPrint
showingSource
sourceOrInfoButton
toggleAltSyntax
toggleDecompile
toggleShowDocumentation
toggleShowingByteCodes

class methods
  no messages
 

instance methods
  annotation top  
 

addOptionalAnnotationsTo:at:plus:

Add an annotation pane to the window if preferences indicate a desire for it, and return the incoming verticalOffset plus the height of the added pane, if any


 

addPriorVersionsCountForSelector:ofClass:to:

add an annotation detailing the prior versions count


 

annotation

Provide a line of content for an annotation pane, representing information about the method associated with the selected class and selector in the receiver.


 

annotationForSelector:ofClass:

Provide a line of content for an annotation pane, representing information about the given selector and class


 

annotationPaneMenu:shifted:


 

annotationRequests


 

annotationSeparator

Answer the separator to be used between annotations


 

defaultAnnotationPaneHeight

Answer the receiver's preferred default height for new annotation panes.


 

defaultButtonPaneHeight

Answer the user's preferred default height for new button panes.


  categories top  
 

categoryOfCurrentMethod

Answer the category that owns the current method. If unable to determine a category, answer nil.


 

changeCategory

Present a menu of the categories of messages for the current class, and let the user choose a new category for the current message


 

methodCategoryChanged


 

selectedMessageCategoryName

Answer the name of the message category of the message of the currently selected context.


  categories & search pane top  
 

listPaneWithSelector:

If, among my window's paneMorphs, there is a list pane defined with aSelector as its retriever, answer it, else answer nil


 

newSearchPane

Answer a new search pane for the receiver


 

searchPane

Answer the search pane associated with the receiver in its window, or nil if none. Morphic only


 

textPaneWithSelector:

If, among my window's paneMorphs, there is a text pane defined with aSelector as its retriever, answer it, else answer nil


  commands top  
 

abbreviatedWordingFor:

Answer the abbreviated form of wording, from a static table which you're welcome to edit. Answer nil if there is no entry -- in which case the long firm will be used on the corresponding browser button.


 

adoptMessageInCurrentChangeset

Add the receiver's method to the current change set if not already there


 

browseImplementors

Create and schedule a message set browser on all implementors of the currently selected message selector. Do nothing if no message is selected.


 

browseSenders

Create and schedule a message set browser on all senders of the currently selected message selector. Of there is no message currently selected, offer a type-in


 

copyUpOrCopyDown

Used to copy down code from a superclass to a subclass or vice-versa in one easy step, if you know what you're doing. Prompt the user for which class to copy down or copy up to, then spawn a fresh browser for that class, with the existing code planted in it, and with the existing method category also established.


 

makeSampleInstance


 

offerMenu

Offer a menu to the user from the bar of tool buttons


 

offerShiftedClassListMenu

Offer the shifted class-list menu.


 

offerUnshiftedClassListMenu

Offer the shifted class-list menu.


 

removeClass

Remove the selected class from the system, at interactive user request. Make certain the user really wants to do this, since it is not reversible. Answer true if removal actually happened.


 

shiftedYellowButtonActivity

Offer the shifted selector-list menu


 

showUnreferencedClassVars

Search for all class variables known to the selected class, and put up a list of those that have no references anywhere in the system. The search includes superclasses, so that you don't need to navigate your way to the class that defines each class variable in order to determine whether it is unreferenced


 

showUnreferencedInstVars

Search for all instance variables known to the selected class, and put up a list of those that have no references anywhere in the system. The search includes superclasses, so that you don't need to navigate your way to the class that defines each inst variable in order to determine whether it is unreferenced


 

spawn:

Create and schedule a spawned message category browser for the currently selected message category. The initial text view contains the characters in aString. In the spawned browser, preselect the current selector (if any) as the going-in assumption, though upon acceptance this will often change


 

spawnFullProtocol

Create and schedule a new protocol browser on the currently selected class or meta.


 

spawnHierarchy

Create and schedule a new class hierarchy browser on the currently selected class or meta.


 

spawnProtocol

Create and schedule a new protocol browser on the currently selected class or meta.


 

spawnToClass:

Used to copy down code from a superclass to a subclass in one easy step, if you know what you're doing. Spawns a new message-category browser for the indicated class, populating it with the source code seen in the current tool.


 

spawnToCollidingClass:

Potentially used to copy down code from a superclass to a subclass in one easy step, in the case where the given class already has its own version of code, which would consequently be clobbered if the spawned code were accepted.


 

unshiftedYellowButtonActivity

Offer the unshifted shifted selector-list menu


  construction top  
 

addLowerPanesTo:at:with:


 

buildClassBrowserEditString:

Create and schedule a new class browser for the current selection, with initial textual contents set to aString. This is used specifically in spawning where a class is established but a method-category is not.


 

buildMorphicCodePaneWith:


  contents top  
 

commentContents

documentation for the selected method


 

contents

Answer the source code or documentation for the selected method


 

contentsChanged


 

contentsSymbol

Answer a symbol indicating what kind of content should be shown for the method; for normal showing of source code, this symbol is #source. A nil value in the contentsSymbol slot will be set to #source by this method


 

contentsSymbol:

Set the contentsSymbol as indicated. #source means to show source code, #comment means to show the first comment found in the source code


  controls top  
 

addOptionalButtonsTo:at:plus:

If the receiver wishes it, add a button pane to the window, and answer the verticalOffset plus the height added


 

buttonWithSelector:

If receiver has a control button with the given action selector answer it, else answer nil. morphic only at this point


 

codePaneProvenanceButton

Answer a button that reports on, and allow the user to modify, the code-pane-provenance setting


 

codePaneProvenanceString

Answer a string that reports on code-pane-provenance


 

contentsSymbolQuints

Answer a list of quintuplets representing information on the alternative views available in the code pane
first element: the contentsSymbol used
second element: the selector to call when this item is chosen.
third element: the selector to call to obtain the wording of the menu item.
fourth element: the wording to represent this view
fifth element: balloon help
A hypen indicates a need for a seperator line in a menu of such choices


 

decorateButtons

Change screen feedback for any buttons in the UI of the receiver that may wish it. Initially, it is only the Inheritance button that is decorated, but one can imagine others.


 

decorateForInheritance

Check to see if the currently-viewed method has a super send or an override, and if so, change screen feedback, unless the #decorateBrowserButtons says not to.


 

inheritanceButton

If receiver has an Inheritance button, answer it, else answer nil. morphic only at this point


 

optionalButtonPairs

Answer a tuple (formerly pairs) defining buttons, in the format:
button label
selector to send
help message


 

optionalButtonRow

Answer a row of control buttons


 

sourceAndDiffsQuintsOnly

Answer a list of quintuplets representing information on the alternative views available in the code pane for the case where the only plausible choices are showing source or either of the two kinds of diffs


  diffs top  
 

defaultDiffsSymbol

Answer the code symbol to use when generically switching to diffing


 

diffButton

Return a checkbox that lets the user decide whether diffs should be shown or not. Not sent any more but retained against the possibility of existing subclasses outside the base image using it.


 

diffFromPriorSourceFor:

If there is a prior version of source for the selected method, return a diff, else just return the source code


 

prettyDiffButton

Return a checkbox that lets the user decide whether prettyDiffs should be shown or not


 

regularDiffButton

Return a checkbox that lets the user decide whether regular diffs should be shown or not


 

restoreTextualCodingPane

If the receiver is showing tiles, restore the textual coding pane


 

showDiffs

Answer whether the receiver is showing diffs of source code. The preferred protocol here is #showingRegularDiffs, but this message is still sent by some preexisting buttons so is retained.


 

showDiffs:

Set whether I'm showing diffs as indicated; use the global preference to determine which kind of diffs to institute.


 

showPrettyDiffs:

Set whether I'm showing pretty diffs as indicated


 

showRegularDiffs:

Set whether I'm showing regular diffs as indicated


 

showingAnyKindOfDiffs

Answer whether the receiver is currently set to show any kind of diffs


 

showingDiffsString

Answer a string representing whether I'm showing diffs. Not sent any more but retained so that prexisting buttons that sent this will not raise errors.


 

showingPrettyDiffs

Answer whether the receiver is showing pretty diffs of source code


 

showingPrettyDiffsString

Answer a string representing whether I'm showing pretty diffs


 

showingRegularDiffs

Answer whether the receiver is showing regular diffs of source code


 

showingRegularDiffsString

Answer a string representing whether I'm showing regular diffs


 

toggleColorPrint

Toggle whether color-print is in effect in the code pane


 

toggleDiff

Retained for backward compatibility with existing buttons in existing images


 

toggleDiffing

Toggle whether diffs should be shown in the code pane. If any kind of diffs were being shown, stop showing diffs. If no kind of diffs were being shown, start showing whatever kind of diffs are called for by default.


 

togglePlainSource

Toggle whether plain source shown in the code pane


 

togglePrettyDiffing

Toggle whether pretty-diffing should be shown in the code pane


 

togglePrettyPrint

Toggle whether pretty-print is in effectin the code pane


 

toggleRegularDiffing

Toggle whether regular-diffing should be shown in the code pane


 

wantsDiffFeedback

Answer whether the receiver is showing diffs of source code


  message category functions top  
 

canShowMultipleMessageCategories

Answer whether the receiver is capable of showing multiple message categories


  message list top  
 

decompiledSourceIntoContents

Obtain a source string by decompiling the method's code, and place that source string into my contents. Get temps from source file


 

selectedBytecodes


 

selectedMessage

Answer a copy of the source code for the selected message. This generic version is probably actually never reached, since every subclass probably reimplements and does not send to super. In time, ideally, most, or all, reimplementors would vanish and all would defer instead to a universal version right here. Everything in good time.


 

sourceStringPrettifiedAndDiffed

Answer a copy of the source code for the selected message, transformed by diffing and pretty-printing exigencies


 

validateMessageSource:forSelector:

Check whether there is evidence that method source is invalid


  message list menu top  
 

messageListKey:from:

Respond to a Command key. I am a model with a code pane, and I also
have a listView that has a list of methods. The view knows how to get
the list and selection.


  misc top  
 

getSelectorAndSendQuery:to:

Obtain a selector relevant to the current context, and then send the querySelector to the queryPerformer with the selector obtained as its argument. If no message is currently selected, then obtain a method name from a user type-in


 

getSelectorAndSendQuery:to:with:

Obtain a selector relevant to the current context, and then send the querySelector to the queryPerformer with the selector obtained and queryArgs as its arguments. If no message is currently selected, then obtain a method name from a user type-in


 

isThereAnOverride

Answer whether any subclass of my selected class implements my selected selector


 

menuButton

Answer a button that brings up a menu. Useful when adding new features, but at present is between uses


 

modelWakeUpIn:

The window has been activated. Respond to possible changes that may have taken place while it was inactive


 

okayToAccept

Answer whether it is okay to accept the receiver's input


 

priorSourceOrNil

If the currently-selected method has a previous version, return its source, else return nil


 

refreshAnnotation

If the receiver has an annotation pane that does not bear unaccepted edits, refresh it


 

refusesToAcceptCode

Answer whether receiver, given its current contentsSymbol, could accept code happily if asked to


 

releaseCachedState

Can always be found again. Don't write on a file.


 

sampleInstanceOfSelectedClass

Return a sample instance of the class currently being pointed at


 

sendQuery:to:

Apply a query to the primary selector associated with the current context. If no such selection exists, obtain one by user type-in. Then send querySelector to queryPerformer with the selector as its argument.


 

setClassAndSelectorIn:

Evaluate csBlock with my selected class and and selector as its arguments; provide nil arguments if I don't have a method currently selected


 

suggestCategoryToSpawnedBrowser:

aBrowser is a message-category browser being spawned from the receiver. Tell it what it needs to know to get its category info properly set up.


 

useSelector:orGetSelectorAndSendQuery:to:

If incomingSelector is not nil, use it, else obtain a selector from user type-in. Using the determined selector, send the query to the performer provided.


  self-updating top  
 

didCodeChangeElsewhere

Determine whether the code for the currently selected method and class has been changed somewhere else.


 

stepIn:


 

updateCodePaneIfNeeded

If the code for the currently selected method has changed underneath me, then update the contents of my code pane unless it holds unaccepted edits


 

updateListsAndCodeIn:


 

wantsStepsIn:


  tiles top  
 

addModelItemsToWindowMenu:

Add model-related item to the window menu


 

installTextualCodingPane

Install text into the code pane


 

installTilesForSelection

Install universal tiles into the code pane.


 

showTiles:

Set the showingTiles as indicated. The fact that there are initially no senders of this reflects that fact that initially this trait is only directly settable through the UI; later there may be senders, such as if one wanted to set a system up so that all newly-opened browsers showed tiles rather than text.


 

showingTiles

Answer whether the receiver is currently showing tiles


 

showingTilesString

Answer a string characterizing whether tiles are currently showing or not


 

tilesToggleButton

Return a checkbox that lets the user decide whether tiles or textual source should show in the code pane


 

toggleShowingTiles

Toggle whether tiles should be shown in the code pane


  what to show top  
 

addContentsTogglesTo:

Add updating menu toggles governing contents to aMenu.


 

colorPrintString

Answer whether the receiver is showing colorPrint


 

offerWhatToShowMenu

Offer a menu governing what to show


 

prettyPrintString

Answer whether the receiver is showing pretty-print


 

setContentsToForceRefetch

Set the receiver's contents such that on the next update the contents will be formulated afresh. This is a critical and obscure difference between Browsers on the one hand and MessageSets on the other, and has over the years been the source of much confusion and much difficulty. By centralizing the different handling here, we don't need so many idiosyncratic overrides in MessageSet any more


 

showAltSyntax:

Set the decompile toggle as indicated


 

showByteCodes:

Get into or out of bytecode-showoing mode


 

showComment

Answer whether the receiver should show documentation rather than, say, source code


 

showDecompile:

Set the decompile toggle as indicated


 

showDocumentation:

Set the showDocumentation toggle as indicated


 

showingAltSyntax

Answer whether the receiver should show alt syntax rather than, say, source code


 

showingAltSyntaxString

Answer a string characerizing whether altSyntax is showing


 

showingByteCodes

Answer whether the receiver is showing bytecodes


 

showingByteCodesString

Answer whether the receiver is showing bytecodes


 

showingColorPrint

Answer whether the receiver is showing color-pretty-print


 

showingDecompile

Answer whether the receiver should show decompile rather than, say, source code


 

showingDecompileString

Answer a string characerizing whether decompilation is showing


 

showingDocumentation

Answer whether the receiver should show documentation rather than, say, source code


 

showingDocumentationString

Answer a string characerizing whether documentation is showing


 

showingPlainSource

Answer whether the receiver is showing plain source


 

showingPlainSourceString

Answer a string telling whether the receiver is showing plain source


 

showingPrettyPrint

Answer whether the receiver is showing pretty-print


 

showingSource

Answer whether the receiver is currently showing source code


 

sourceOrInfoButton

Return a checkbox that lets the user decide whether the full source or just documentation should show in the code pane


 

toggleAltSyntax

Toggle the setting of the showingAltSyntax flag, unless there are unsubmitted edits that the user declines to discard


 

toggleDecompile

Toggle the setting of the showingDecompile flag, unless there are unsubmitted edits that the user declines to discard


 

toggleShowDocumentation

Toggle the setting of the showingDocumentation flag, unless there are unsubmitted edits that the user declines to discard


 

toggleShowingByteCodes

Toggle whether the receiver is showing bytecodes


class methods
  no messages top