-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
Extension { #name : #FASTEntitySourceAnchor } | ||
|
||
{ #category : #'*FAST-GTExtensions' } | ||
FASTEntitySourceAnchor >> gtNodesIn: composite [ | ||
<gtInspectorPresentationOrder: 0> | ||
^ composite tree | ||
title: 'Tree'; | ||
display: [ :anObject | anObject ]; | ||
children: [ :each | each childrenNode ]; | ||
yourself | ||
] | ||
|
||
{ #category : #'*FAST-GTExtensions' } | ||
FASTEntitySourceAnchor >> gtSourceCodeIn: composite [ | ||
<gtInspectorPresentationOrder: 0> | ||
^ composite text | ||
title: 'Source code'; | ||
display: [ self ]; | ||
format: [ :t | self sourceText ifNil: [ 'No source code available' ] ifNotNil: [ self sourceCodeAsText ] ]; | ||
withLineNumbers: true; | ||
initialize: [ :presentation | (self sourceText isNil or: [ self startPos isNil or: [ self endPos isNil ] ]) ifFalse: [ presentation selectionInterval: (self startPos to: self endPos) ] ]; | ||
yourself | ||
] | ||
|
||
{ #category : #'*FAST-GTExtensions' } | ||
FASTEntitySourceAnchor >> sourceCodeAsText [ | ||
^ self sourceText asText | ||
] |