diff --git a/repository/OpenPonk-Core/OPBoundary.class.st b/repository/OpenPonk-Core/OPBoundary.class.st index d89cd820..35c1c80a 100644 --- a/repository/OpenPonk-Core/OPBoundary.class.st +++ b/repository/OpenPonk-Core/OPBoundary.class.st @@ -1,6 +1,8 @@ Class { #name : 'OPBoundary', #superclass : 'OPDiagramOnlyShapeWithText', + #traits : 'OPTColoredAsFillAndBorderColoredAsStroke', + #classTraits : 'OPTColoredAsFillAndBorderColoredAsStroke classTrait', #instVars : [ 'name' ], @@ -24,11 +26,23 @@ OPBoundary >> addSelectionDraggableInteraction [ @ OPRSSelectionDraggableBorder thatAlsoDragsContainedShapes ] +{ #category : 'accessing' } +OPBoundary >> defaultFillColor [ + + ^ Color transparent +] + { #category : 'accessing' } OPBoundary >> defaultHeight [ ^ 400 ] +{ #category : 'accessing' } +OPBoundary >> defaultStrokeColor [ + + ^ Color gray slightlyDarker +] + { #category : 'accessing' } OPBoundary >> defaultWidth [ ^ 500 @@ -64,21 +78,17 @@ OPBoundary >> printOn: aStream [ nextPutAll: ''')' ] -{ #category : 'creating - subelements' } +{ #category : 'rendering' } OPBoundary >> renderBasicShape [ ^ RSBox new - color: Color transparent; width: self defaultWidth; height: self defaultHeight; - borderDo: [ :border | - border - color: Color gray; - dashArray: #( 4 ) ]; + borderDo: [ :border | border dashArray: #( 4 ) ]; yourself ] -{ #category : 'creating - subelements' } +{ #category : 'interactions' } OPBoundary >> selectableInteraction [ ^ OPRSSelectable diff --git a/repository/OpenPonk-Core/OPCommonElementController.class.st b/repository/OpenPonk-Core/OPCommonElementController.class.st index 7965bbb9..7f45a6fe 100644 --- a/repository/OpenPonk-Core/OPCommonElementController.class.st +++ b/repository/OpenPonk-Core/OPCommonElementController.class.st @@ -45,6 +45,12 @@ OPCommonElementController >> isCommon [ ^ true ] +{ #category : 'testing' } +OPCommonElementController >> isHideable [ + + ^ false +] + { #category : 'accessing' } OPCommonElementController >> model [ diff --git a/repository/OpenPonk-Core/OPController.class.st b/repository/OpenPonk-Core/OPController.class.st index 9191907d..b3e518dd 100644 --- a/repository/OpenPonk-Core/OPController.class.st +++ b/repository/OpenPonk-Core/OPController.class.st @@ -163,6 +163,7 @@ OPController >> internalUnsubscribeFrom: aModel [ { #category : 'testing' } OPController >> isHideable [ + ^ false ] diff --git a/repository/OpenPonk-Core/OPDiagramController.class.st b/repository/OpenPonk-Core/OPDiagramController.class.st index 72c0c3e5..5204b047 100644 --- a/repository/OpenPonk-Core/OPDiagramController.class.st +++ b/repository/OpenPonk-Core/OPDiagramController.class.st @@ -767,7 +767,7 @@ OPDiagramController >> typeOfModel: aModel [ ^ OPModelObjectType named: ((aModel className withoutPrefix: self commonModelClassPrefix) - splitOnCapitals joinUsing: ' ') + splitCamelCase joinUsing: ' ') ] { #category : 'undo/redo' } diff --git a/repository/OpenPonk-Core/OPDiagramElement.class.st b/repository/OpenPonk-Core/OPDiagramElement.class.st index 67260793..57af048d 100644 --- a/repository/OpenPonk-Core/OPDiagramElement.class.st +++ b/repository/OpenPonk-Core/OPDiagramElement.class.st @@ -426,6 +426,13 @@ OPDiagramElement >> removeRender [ roassalShape := nil ] +{ #category : 'accessing' } +OPDiagramElement >> removeStylePropertyNamed: aName [ + + self localStyle ifNotNil: [ :style | + style removeKey: aName ifAbsent: [ ] ] +] + { #category : 'rendering' } OPDiagramElement >> renderBasicShape [ diff --git a/repository/OpenPonk-Core/OPDiagramOnlyShape.class.st b/repository/OpenPonk-Core/OPDiagramOnlyShape.class.st index 8092f950..6aa31d1d 100644 --- a/repository/OpenPonk-Core/OPDiagramOnlyShape.class.st +++ b/repository/OpenPonk-Core/OPDiagramOnlyShape.class.st @@ -1,8 +1,6 @@ Class { #name : 'OPDiagramOnlyShape', #superclass : 'OPBoundNode', - #traits : 'OPTBorderColoredAsStroke - {#updateRenderFromStyles}', - #classTraits : 'OPTBorderColoredAsStroke classTrait', #instVars : [ 'uuid', 'announcer' @@ -67,12 +65,6 @@ OPDiagramOnlyShape >> modelElements: aCollection [ self shouldNotImplement ] -{ #category : 'accessing' } -OPDiagramOnlyShape >> strokeColor: aColor [ - - "ignore for now" -] - { #category : 'rendering' } OPDiagramOnlyShape >> updateRenderFromModel [ diff --git a/repository/OpenPonk-Core/OPEditElementTextCommand.class.st b/repository/OpenPonk-Core/OPEditElementTextCommand.class.st index e5e17253..71d96f76 100644 --- a/repository/OpenPonk-Core/OPEditElementTextCommand.class.st +++ b/repository/OpenPonk-Core/OPEditElementTextCommand.class.st @@ -30,7 +30,7 @@ OPEditElementTextCommand class >> executeAccessor: anAccessor on: anObject [ OPEditElementTextCommand >> accessor: anAccessor [ self getSelector: anAccessor. self setSelector: anAccessor , ':'. - self name: (anAccessor capitalized splitOnCapitals joinUsing: ' ') + self name: (anAccessor capitalized splitCamelCase joinUsing: ' ') ] { #category : 'execute' } diff --git a/repository/OpenPonk-Core/OPElementController.class.st b/repository/OpenPonk-Core/OPElementController.class.st index 0cc2223a..30754a08 100644 --- a/repository/OpenPonk-Core/OPElementController.class.st +++ b/repository/OpenPonk-Core/OPElementController.class.st @@ -131,6 +131,12 @@ OPElementController >> isCommon [ ^ false ] +{ #category : 'testing' } +OPElementController >> isHideable [ + + ^ true +] + { #category : 'deprecated' } OPElementController >> loadModel [ self deprecated: 'Method will be removed without replacement.' diff --git a/repository/OpenPonk-Core/OPNoModelAdapter.class.st b/repository/OpenPonk-Core/OPNoModelAdapter.class.st new file mode 100644 index 00000000..de1a4954 --- /dev/null +++ b/repository/OpenPonk-Core/OPNoModelAdapter.class.st @@ -0,0 +1,29 @@ +Class { + #name : 'OPNoModelAdapter', + #superclass : 'Object', + #classInstVars : [ + 'instance' + ], + #category : 'OpenPonk-Core-Adapters', + #package : 'OpenPonk-Core', + #tag : 'Adapters' +} + +{ #category : 'accessing' } +OPNoModelAdapter class >> instance [ + + ^ instance ifNil: [ instance := self basicNew ] +] + +{ #category : 'instance creation' } +OPNoModelAdapter class >> new [ + + ^ self instance +] + +{ #category : 'initialization' } +OPNoModelAdapter class >> reset [ + +