diff --git a/src/PetitMarkdown/PPCMDocument.class.st b/src/PetitMarkdown/PPCMDocument.class.st index 580cc95..94ab901 100644 --- a/src/PetitMarkdown/PPCMDocument.class.st +++ b/src/PetitMarkdown/PPCMDocument.class.st @@ -48,5 +48,5 @@ PPCMDocument >> viewChildrenFor: aView [ items: [ { self } ]; children: #children; column: 'Name' text: #viewBody; - expandUpTo: 6 + expandUpTo: 7 ] diff --git a/src/PetitMarkdown/PPCMLine.class.st b/src/PetitMarkdown/PPCMLine.class.st index 51505eb..484f3ed 100644 --- a/src/PetitMarkdown/PPCMLine.class.st +++ b/src/PetitMarkdown/PPCMLine.class.st @@ -35,3 +35,26 @@ PPCMLine >> text [ children do: [ :child | stream nextPutAll: child text ]. ^ stream contents ] + +{ #category : #accessing } +PPCMLine >> viewBody [ + + | aText | + aText := (self className ,' ', self text) asRopedText. + + self children do: [ :child | + aText append: ' ' asRopedText. + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: ('= "' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: + ('"' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor) + ]. + + + ^ aText +] diff --git a/src/PetitMarkdown/PPCMLink.class.st b/src/PetitMarkdown/PPCMLink.class.st index 7776f78..92076ea 100644 --- a/src/PetitMarkdown/PPCMLink.class.st +++ b/src/PetitMarkdown/PPCMLink.class.st @@ -43,3 +43,27 @@ PPCMLink >> title [ PPCMLink >> title: anObject [ title := anObject ] + +{ #category : #accessing } +PPCMLink >> viewBody [ + + | aText | + aText := (self className ,' ', + self label children first text, ' -> ', self destination) asRopedText. + + self children do: [ :child | + aText append: ' ' asRopedText. + aText append: (child destination asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: ('= "' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: (child destination asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: + ('"' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor) + ]. + + + ^ aText +] diff --git a/src/PetitMarkdown/PPCMSoftBreak.class.st b/src/PetitMarkdown/PPCMSoftBreak.class.st index d80b389..a054488 100644 --- a/src/PetitMarkdown/PPCMSoftBreak.class.st +++ b/src/PetitMarkdown/PPCMSoftBreak.class.st @@ -8,3 +8,26 @@ Class { PPCMSoftBreak >> accept: visitor [ ^ visitor visitSoftBreak: self ] + +{ #category : #accessing } +PPCMSoftBreak >> viewBody [ + + | aText | + aText := (self className ,' ', self text) asRopedText. + + self children do: [ :child | + aText append: ' ' asRopedText. + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: ('= "' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: + ('"' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor) + ]. + + + ^ aText +] diff --git a/src/PetitMarkdown/PPCMText.class.st b/src/PetitMarkdown/PPCMText.class.st index 9c6fef4..c6d2f6b 100644 --- a/src/PetitMarkdown/PPCMText.class.st +++ b/src/PetitMarkdown/PPCMText.class.st @@ -53,3 +53,26 @@ PPCMText >> text [ PPCMText >> text: anObject [ text := anObject ] + +{ #category : #accessing } +PPCMText >> viewBody [ + + | aText | + aText := (self className ,' ', self text) asRopedText. + + self children do: [ :child | + aText append: ' ' asRopedText. + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: ('= "' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: (child text asRopedText foreground: + BrGlamorousColors disabledButtonTextColor). + aText append: + ('"' asRopedText foreground: + BrGlamorousColors disabledButtonTextColor) + ]. + + + ^ aText +]