Actually - Iâve realised that Calypso can give me the tag name from its context - (aToolContext lastSelectedClassGroup). However it does highlight a very strange package/tag design. Are you not supposed to be easily able to derive RPacakgeTags? Tim
On 14 Feb 2019, at 13:19, Tim Mackinnon <tim@testit.works> wrote:
Iâm trying to understand how RPackage and RPackageTag work in Pharo7? It seems different than Pharo6 at least with Nautilus (vs Calypso) - as previously the Nautilus UI gave me the RPacakgeTag, and I could just work with that. Calypso doesnât seem to give me the tag object, but if I have a known class and I want to know its RPackageTag I canât see how you do it? It all seems rather messyâ¦.
I can ask a class for its category - which just gives me a symbol of the form âmypackage-tagnameâ, and if I ask a class for its package, it will give me an RPackage(myPackage) - but that RPackage has a set of RPackageTags which just use the tagname (so not prefixed with "mypackage-â)? So am I really supposed to split the category name on â-â myself, and then select the correct RPackageTag?
If I look at the RPackageTag tests - they all seem to use hard coded values and so donât really show you how you deal with the question above?
It really seems quite messy?
I naively thought that if I wanted a browser extension to deal with a selected package tag - and file out some classes in that tag (for exercism) - I could easily get the RPackageTag from any class and then use it?
Tim