From af473eebfdc17f887455102bad0c5a634fe064a7 Mon Sep 17 00:00:00 2001 From: Pierre Laborde <49183340+labordep@users.noreply.github.com> Date: Fri, 29 Aug 2025 13:14:46 +0200 Subject: [PATCH 1/3] update readme --- README.md | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index ba189ff6..0059b1d7 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ You can add plugins into Pyramid to extend the editor capacities or create [your You can load a release version of Pyramid or the latest development version. Beware that Pyramid is currently in alpha development. The API is subject to significant changes, and stability is not guaranteed. Projects created during the alpha version are not designed to be compatible with newer versions of Pyramid. -Pyramid is available with Bloc and Toplo as defaults. If you want to build UI without Toplo, you can choose to load Pyramid with only Bloc using the baseline option `load: 'BlocUI'`. Here's an example script below. +Pyramid is available with Bloc and Toplo as defaults. To install a version of Pyramid, use one of the following scripts inside a playground. @@ -41,22 +41,11 @@ To install a version of Pyramid, use one of the following scripts inside a playg ```st Metacello new baseline: 'Pyramid'; - repository: 'github://OpenSmock/Pyramid:main/src'; + repository: 'github://OpenSmock/Pyramid:main'; onConflictUseLoaded; load ``` -Only with Bloc (without Toplo features): - -```st -Metacello new - baseline: 'Pyramid'; - repository: 'github://OpenSmock/Pyramid:main/src'; - onConflictUseLoaded; - load: 'BlocUI'; - load -``` - ### Release version We advise you to use dependencies committed at the date of the Pyramid release (Bloc, Bloc-Serialization, etc.) to ensure compatibility with a release of Pyramid. @@ -64,7 +53,7 @@ We advise you to use dependencies committed at the date of the Pyramid release ( ```st Metacello new baseline: 'Pyramid'; - repository: 'github://OpenSmock/Pyramid:alpha4'; + repository: 'github://OpenSmock/Pyramid:alpha8'; onConflictUseLoaded; load ``` @@ -72,7 +61,7 @@ Metacello new ### Add in your baseline ```st -spec baseline: 'Pyramid' with: [ spec repository: 'github://OpenSmock/Pyramid:main/src' ]. +spec baseline: 'Pyramid' with: [ spec repository: 'github://OpenSmock/Pyramid:main' ]. ``` ## How to use Pyramid @@ -147,8 +136,7 @@ https://github.com/OpenSmock/Pyramid/assets/49183340/0c66a3ac-7bea-48c1-b1e8-0b0 - [Toplo](https://github.com/pharo-graphics/Toplo) - a widget framework on top of Bloc. - [STON](https://github.com/svenvc/ston) - serializer for Pharo objects to Smalltalk Object Notation format. - [Stash](https://github.com/Nyan11/Stash) - serializer for Pharo objects to source code format. - -**Pharo 12 compatibility:** On Pharo 12, [PharoBackwardCompatibility](https://github.com/jecisc/PharoBackwardCompatibility) is automatically loaded via the baseline to ensure compatibility. +- [PharoBackwardCompatibility](https://github.com/jecisc/PharoBackwardCompatibility) - Automatically ensure compatibility with old versions of Pharo. ## License From 6bcc2b9afdc7bacd704013f2cb2f71bebca74bec Mon Sep 17 00:00:00 2001 From: Pierre Laborde <49183340+labordep@users.noreply.github.com> Date: Fri, 29 Aug 2025 13:19:03 +0200 Subject: [PATCH 2/3] Clean baseline --- src/BaselineOfPyramid/BaselineOfPyramid.class.st | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/BaselineOfPyramid/BaselineOfPyramid.class.st b/src/BaselineOfPyramid/BaselineOfPyramid.class.st index f3afd060..523ed4a8 100644 --- a/src/BaselineOfPyramid/BaselineOfPyramid.class.st +++ b/src/BaselineOfPyramid/BaselineOfPyramid.class.st @@ -22,7 +22,7 @@ BaselineOfPyramid >> baselineForCommon: spec [ "Pharo backward compatibility: to preserve running from previous versions of Pharo" spec baseline: 'PharoBackwardCompatibility' - with: [ spec repository: 'github://jecisc/PharoBackwardCompatibility:master/src' ]. + with: [ spec repository: 'github://jecisc/PharoBackwardCompatibility:master' ]. "Dependencies" self blocDependencies: spec. @@ -45,7 +45,7 @@ BaselineOfPyramid >> blocDependencies: spec [ spec baseline: 'BlocSerialization' with: [ - spec repository: 'github://OpenSmock/Bloc-Serialization:main/src' ] + spec repository: 'github://OpenSmock/Bloc-Serialization:main' ] ] { #category : #packages } @@ -101,7 +101,7 @@ BaselineOfPyramid >> toploDependencies: spec [ spec baseline: 'ToploSerialization' with: [ - spec repository: 'github://OpenSmock/Toplo-Serialization:main/src' ] + spec repository: 'github://OpenSmock/Toplo-Serialization:main' ] ] { #category : #packages } From 42bd42ec6860792c09950e4138807f5c22f883d3 Mon Sep 17 00:00:00 2001 From: Pierre Laborde <49183340+labordep@users.noreply.github.com> Date: Fri, 29 Aug 2025 13:36:31 +0200 Subject: [PATCH 3/3] About panel: Fix logo size (too big). Write a test for menu extension using pragma. --- .../PyramidWorldTest.class.st | 38 +++++++++++++++++++ src/Pyramid-IDE/PyramidWorld.class.st | 2 +- 2 files changed, 39 insertions(+), 1 deletion(-) diff --git a/src/Pyramid-IDE-Tests/PyramidWorldTest.class.st b/src/Pyramid-IDE-Tests/PyramidWorldTest.class.st index 56594c80..7e5eaeb8 100644 --- a/src/Pyramid-IDE-Tests/PyramidWorldTest.class.st +++ b/src/Pyramid-IDE-Tests/PyramidWorldTest.class.st @@ -4,9 +4,45 @@ A PyramidWorldTest is a test class for testing the behavior of PyramidWorld Class { #name : #PyramidWorldTest, #superclass : #TestCase, + #classInstVars : [ + 'worldMenuItemCheck' + ], #category : #'Pyramid-IDE-Tests-menus' } +{ #category : #accessing } +PyramidWorldTest class >> worldMenuItemCheck [ + + ^ worldMenuItemCheck +] + +{ #category : #accessing } +PyramidWorldTest class >> worldMenuItemCheck: anObject [ + + worldMenuItemCheck := anObject +] + +{ #category : #'tests - menu' } +PyramidWorldTest class >> worldMenuItemTestMethod: anItem [ + "This method check if the pragma mecanism to setup a menu item is working" + "Be aware to not inject behavior here because this is just a test method ant it is called when the menu is build!" + + + worldMenuItemCheck := true. + + anItem ifNil:[ Exception signal: 'Menu item should be not nil' ]. + anItem item = (PyramidWorld menuKey) ifFalse:[ Exception signal: 'Menu item should be equals to ', PyramidWorld menuKey printString ]. +] + +{ #category : #running } +PyramidWorldTest >> setUp [ + + super setUp. + + self class worldMenuItemCheck: false. + self deny: self class worldMenuItemCheck. +] + { #category : #tests } PyramidWorldTest >> testCleanUp [ @@ -59,4 +95,6 @@ PyramidWorldTest >> testWorldMenuBuilding [ menuMethods do:[ :p | PyramidWorld perform: p with: menuBuilder. ]. + + self assert: self class worldMenuItemCheck. ] diff --git a/src/Pyramid-IDE/PyramidWorld.class.st b/src/Pyramid-IDE/PyramidWorld.class.st index 5711ad1a..6866c0ce 100644 --- a/src/Pyramid-IDE/PyramidWorld.class.st +++ b/src/Pyramid-IDE/PyramidWorld.class.st @@ -1057,7 +1057,7 @@ PyramidWorld class >> openAbout [ SpInformDialog new title: ('About ', PyramidWindow aboutTitle); - icon: (self themeIcons iconNamed: #logotype512); + icon: ((self themeIcons iconNamed: #cartouche512) scaledToSize: 200 asPoint); label: PyramidWindow aboutText; acceptLabel: 'Close'; openDialog