-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #202 from OpenSmock/Issue_0158
Issue 0158
- Loading branch information
Showing
53 changed files
with
1,006 additions
and
716 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
Extension { #name : #BlBezierCurveGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlBezierCurveGeometry class >> asIcon [ | ||
|
||
^ super asIcon copy: (0 @ 12 extent: 16 @ 12) | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlBezierCurveGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self controlPoints: { | ||
(0 @ 0). | ||
(0 @ 75). | ||
(50 @ -25). | ||
(50 @ 50) } | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlBezierCurveGeometry class >> pyramidDefaultValueForIcon [ | ||
|
||
^ self controlPoints: { | ||
(0 @ 0). | ||
(0 @ 24). | ||
(16 @ -12). | ||
(16 @ 12) } | ||
] |
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,41 @@ | ||
Extension { #name : #BlElementGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlElementGeometry class >> asIcon [ | ||
|
||
| element | | ||
element := BlElement new | ||
size: 16 @ 12; | ||
background: (Color gray: 0.75); | ||
border: (BlBorder paint: Color black width: 1); | ||
geometry: self pyramidDefaultValueForIcon; | ||
yourself. | ||
^ element exportAsForm | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlElementGeometry class >> asPyramidMagicButton [ | ||
|
||
^ PyramidMagicButtonModel new | ||
icon: self asIcon; | ||
helpSelected: | ||
('The geometry is <1s>.' expandMacrosWith: self name); | ||
helpNotSelected: | ||
('Set the geometry to <1s>.' expandMacrosWith: self name); | ||
label: ''; | ||
inputValue: self pyramidDefaultValue; | ||
inputValidation: [ :value | value isKindOf: self ]; | ||
yourself | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlElementGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self new | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlElementGeometry class >> pyramidDefaultValueForIcon [ | ||
|
||
^ self pyramidDefaultValue | ||
] |
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,13 @@ | ||
Extension { #name : #BlLineGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlLineGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self from: 0 asPoint to: 50 asPoint | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlLineGeometry class >> pyramidDefaultValueForIcon [ | ||
|
||
^ self from: 0 asPoint to: 12 asPoint | ||
] |
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,19 @@ | ||
Extension { #name : #BlPolygonGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlPolygonGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self vertices: { | ||
(0 @ 50). | ||
(0 @ 0). | ||
(25 @ 25). | ||
(50 @ 0). | ||
(50 @ 50) } | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlPolygonGeometry class >> pyramidDefaultValueForIcon [ | ||
|
||
^ self vertices: | ||
(self pyramidDefaultValue vertices collect: [ :each | each / 4.2 ]) | ||
] |
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,18 @@ | ||
Extension { #name : #BlPolylineGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlPolylineGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self vertices: { | ||
(0 @ 50). | ||
(0 @ 0). | ||
(25 @ 25). | ||
(50 @ 0). | ||
(50 @ 50) } | ||
] | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlPolylineGeometry class >> pyramidDefaultValueForIcon [ | ||
|
||
^ self vertices: (self pyramidDefaultValue vertices collect: [ :each | each / 4.2 ]) | ||
] |
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,7 @@ | ||
Extension { #name : #BlRoundedRectangleGeometry } | ||
|
||
{ #category : #'*Pyramid-Bloc' } | ||
BlRoundedRectangleGeometry class >> pyramidDefaultValue [ | ||
|
||
^ self cornerRadius: 8 | ||
] |
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
Oops, something went wrong.