-
Notifications
You must be signed in to change notification settings - Fork 1
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
31 changed files
with
123 additions
and
63 deletions.
There are no files selected for viewing
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownClosingLinkDelimiter.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
^ 'LinkDelimiter' |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownClosingURLDelimiter.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
^ 'UrlDelimiter' |
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
21 changes: 21 additions & 0 deletions
21
packages/MarkdownEditor-Core.package/MarkdownEditor.class/instance/menubarContent..st
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,21 @@ | ||
building | ||
menubarContent: aBuilder | ||
^ { | ||
aBuilder pluggableButtonSpec new | ||
label: 'New'; | ||
model: self; | ||
enabled: true; | ||
action: #createNewInstance; | ||
yourself. | ||
aBuilder pluggableButtonSpec new | ||
label: 'Convert to Html'; | ||
model: self; | ||
enabled: true; | ||
action: #convertToHTML; | ||
yourself. | ||
aBuilder pluggableButtonSpec new | ||
label: 'Options'; | ||
model: self; | ||
action: #openSettings; | ||
enabled: true; | ||
yourself } |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownEmphasisDelimiter.class/instance/type.st
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,4 @@ | ||
constants | ||
type | ||
|
||
^ 'EmphasisDelimiter' |
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
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
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
12 changes: 12 additions & 0 deletions
12
packages/MarkdownEditor-Core.package/MarkdownInlineElement.class/instance/addTo..st
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,12 @@ | ||
accessing | ||
addTo: aText | ||
|
||
aText | ||
addAttribute: self textAttribute | ||
from: self startPosition | ||
to: self endPosition. | ||
|
||
aText | ||
addAttribute: self colorAttribute | ||
from: self startPosition | ||
to: self endPosition |
1 change: 1 addition & 0 deletions
1
packages/MarkdownEditor-Core.package/MarkdownInlineElement.class/instance/content.st
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 |
---|---|---|
@@ -1,3 +1,4 @@ | ||
accessing | ||
content | ||
|
||
^ content |
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
11 changes: 1 addition & 10 deletions
11
packages/MarkdownEditor-Core.package/MarkdownInlineTextStyler.class/instance/add.to..st
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 |
---|---|---|
@@ -1,13 +1,4 @@ | ||
styling | ||
add: aCollectionOfMarkdownInlineElements to: aText | ||
|
||
aCollectionOfMarkdownInlineElements do: [:element | | ||
aText | ||
addAttribute: element textAttribute | ||
from: element startPosition | ||
to: element endPosition. | ||
|
||
aText | ||
addAttribute: element colorAttribute | ||
from: element startPosition | ||
to: element endPosition]. | ||
aCollectionOfMarkdownInlineElements do: [:element | element addTo: aText] |
18 changes: 4 additions & 14 deletions
18
packages/MarkdownEditor-Core.package/MarkdownInlineTextStyler.class/instance/process.and..st
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 |
---|---|---|
@@ -1,17 +1,7 @@ | ||
parsing | ||
process: opener and: closer | ||
|
||
| length nextToken | | ||
(opener class = MarkdownOpeningLinkDelimiter and: [closer class = MarkdownClosingLinkDelimiter]) | ||
ifTrue: [ self inlineElements add: (self createLinkFrom: opener and: closer). | ||
length := 1. | ||
nextToken := self followingTokenOf: closer. | ||
self processOpeningURLDelimiter: nextToken. | ||
self cutOpener: opener to: length. | ||
^ self cutCloser: closer to: length]. | ||
(opener class = MarkdownEmphasisDelimiter and: [closer class = MarkdownEmphasisDelimiter]) | ||
ifTrue: [ self inlineElements add: (self createEmphasisFrom: opener and: closer). | ||
self removeDelimitersBetween: opener and: closer. | ||
length := closer delimiterLengthForEmphasisWith: opener. | ||
self cutOpener: opener to: length. | ||
^ self cutCloser: closer to: length] | ||
(opener type = 'LinkDelimiter' and: [closer type = 'LinkDelimiter']) | ||
ifTrue: [ ^ self processLink: opener and: closer]. | ||
(opener type = 'EmphasisDelimiter' and: [closer type = 'EmphasisDelimiter']) | ||
ifTrue: [^ self processEmphasis: opener and: closer] |
9 changes: 9 additions & 0 deletions
9
...rkdownEditor-Core.package/MarkdownInlineTextStyler.class/instance/processEmphasis.and..st
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,9 @@ | ||
parsing | ||
processEmphasis: opener and: closer | ||
|
||
| length | | ||
self inlineElements add: (self createEmphasisFrom: opener and: closer). | ||
self removeDelimitersBetween: opener and: closer. | ||
length := closer delimiterLengthForEmphasisWith: opener. | ||
self cutOpener: opener to: length. | ||
^ self cutCloser: closer to: length |
10 changes: 10 additions & 0 deletions
10
...s/MarkdownEditor-Core.package/MarkdownInlineTextStyler.class/instance/processLink.and..st
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,10 @@ | ||
parsing | ||
processLink: opener and: closer | ||
|
||
| length nextToken | | ||
self inlineElements add: (self createLinkFrom: opener and: closer). | ||
length := 1. | ||
nextToken := self followingTokenOf: closer. | ||
self processOpeningURLDelimiter: nextToken. | ||
self cutOpener: opener to: length. | ||
^ self cutCloser: closer to: length |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownOpeningLinkDelimiter.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
^ 'LinkDelimiter' |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownOpeningURLDelimiter.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
^ 'UrlDelimiter' |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownString.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
^ 'String' |
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
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownToken.class/instance/matches..st
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,4 @@ | ||
initialize-release | ||
matches: aMarkdownToken | ||
|
||
^ self type = aMarkdownToken type |
4 changes: 4 additions & 0 deletions
4
packages/MarkdownEditor-Core.package/MarkdownToken.class/instance/type.st
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,4 @@ | ||
initialize-release | ||
type | ||
|
||
self subclassResponsibility |
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