Re: [Pharo-dev] Spotlight Demo
Thanks for the feedback everyone! A few enhancements: - Close on escape - Select next on down arrow when open - Show all on down arrow when closed - Select previous on up arrow - Accept on enter - requires an override in PluggableTextFieldMorph, but I think the change can be integrated in Core - For entry completion (unlike our current behavior): - Keyboard focus remains with the text field, so: - you can continue to type - the selected item stays selected as long as it remains visible, even if it moves around in the list (maybe doesn't matter for completion...) I'm off to celebrate... See you in the new year!
Sounds like a great New Year gift :). I will review the code today. Cheers, Doru On Wed, Jan 1, 2014 at 3:20 AM, DeNigris Sean <sean@clipperadams.com> wrote:
Thanks for the feedback everyone!
A few enhancements: - Close on escape - Select next on down arrow when open - Show all on down arrow when closed - Select previous on up arrow - Accept on enter - requires an override in PluggableTextFieldMorph, but I think the change can be integrated in Core - For entry completion (unlike our current behavior): - Keyboard focus remains with the text field, so: - you can continue to type - the selected item stays selected as long as it remains visible, even if it moves around in the list (maybe doesn't matter for completion...)
I'm off to celebrate... See you in the new year!
-- www.tudorgirba.com "Every thing has its own flow"
Hi, I went only over the functionality for now (I tried in a Pharo #30664 with Moose inside). It starts to be really interesting: - I love it how I can navigate with up/down and still continue typing. This is seriously cool. but :): - Esc has no effect ( - The list entries behave strangely because you use a text morph that can be edited. For example, type something, go with the mouse over an item in the list, you will see the cursor changes to a text one, click, and you can start typing there. Why not use a LabelMorph? - Pressing Enter does not seem to trigger the action associated with a list. Only pressing double click seems to work. - The PluggableTextMorph at the top allows Enter. Pressing Enter leads to a line break. This is not wanted (you asked what I meant by it a field). - The PluggableTextMorph at the top should not indicate dirty state - Pressing up/down also moves the cursor in the top PluggableTextMorph. This should not happen. - It would be interesting to have the count of hits even though we are only displaying a limited amount. The count could be displayed below the label (with a gray color) like: Messages 23 items And a question related to "Show all on down arrow when closed": - I think I did not see this behavior. What does "closed" mean? And what do you mean by "all"? Cheers, Doru On Wed, Jan 1, 2014 at 7:23 AM, Tudor Girba <tudor@tudorgirba.com> wrote:
Sounds like a great New Year gift :). I will review the code today.
Cheers, Doru
On Wed, Jan 1, 2014 at 3:20 AM, DeNigris Sean <sean@clipperadams.com>wrote:
Thanks for the feedback everyone!
A few enhancements: - Close on escape - Select next on down arrow when open - Show all on down arrow when closed - Select previous on up arrow - Accept on enter - requires an override in PluggableTextFieldMorph, but I think the change can be integrated in Core - For entry completion (unlike our current behavior): - Keyboard focus remains with the text field, so: - you can continue to type - the selected item stays selected as long as it remains visible, even if it moves around in the list (maybe doesn't matter for completion...)
I'm off to celebrate... See you in the new year!
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
And it would still be cool if the search would not block the UI process :). Is that on your roadmap? Doru On Wed, Jan 1, 2014 at 9:39 PM, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi,
I went only over the functionality for now (I tried in a Pharo #30664 with Moose inside).
It starts to be really interesting: - I love it how I can navigate with up/down and still continue typing. This is seriously cool.
but :): - Esc has no effect ( - The list entries behave strangely because you use a text morph that can be edited. For example, type something, go with the mouse over an item in the list, you will see the cursor changes to a text one, click, and you can start typing there. Why not use a LabelMorph? - Pressing Enter does not seem to trigger the action associated with a list. Only pressing double click seems to work. - The PluggableTextMorph at the top allows Enter. Pressing Enter leads to a line break. This is not wanted (you asked what I meant by it a field). - The PluggableTextMorph at the top should not indicate dirty state - Pressing up/down also moves the cursor in the top PluggableTextMorph. This should not happen. - It would be interesting to have the count of hits even though we are only displaying a limited amount. The count could be displayed below the label (with a gray color) like: Messages 23 items
And a question related to "Show all on down arrow when closed": - I think I did not see this behavior. What does "closed" mean? And what do you mean by "all"?
Cheers, Doru
On Wed, Jan 1, 2014 at 7:23 AM, Tudor Girba <tudor@tudorgirba.com> wrote:
Sounds like a great New Year gift :). I will review the code today.
Cheers, Doru
On Wed, Jan 1, 2014 at 3:20 AM, DeNigris Sean <sean@clipperadams.com>wrote:
Thanks for the feedback everyone!
A few enhancements: - Close on escape - Select next on down arrow when open - Show all on down arrow when closed - Select previous on up arrow - Accept on enter - requires an override in PluggableTextFieldMorph, but I think the change can be integrated in Core - For entry completion (unlike our current behavior): - Keyboard focus remains with the text field, so: - you can continue to type - the selected item stays selected as long as it remains visible, even if it moves around in the list (maybe doesn't matter for completion...)
I'm off to celebrate... See you in the new year!
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
- I love it how I can navigate with up/down and still continue typing. This is seriously cool.
:) Tudor Girba-2 wrote
- Esc has no effect (
I had implemented it for entry completion. It is working in SpotlighMorph now also. Tudor Girba-2 wrote
- The list entries behave strangely because you use a text morph that can be edited. For example, type something, go with the mouse over an item in the list, you will see the cursor changes to a text one, click, and you can start typing there. Why not use a LabelMorph?
I didn't use LabelMorph because it deals with strings, not text, and I want to be able to e.g. make the matching substring bold like in the examples. But I locked the TextMorphs, so it's fixed. Tudor Girba-2 wrote
- Pressing Enter does not seem to trigger the action associated with a list. Only pressing double click seems to work. - The PluggableTextMorph at the top allows Enter. Pressing Enter leads to a line break. This is not wanted (you asked what I meant by it a field). - The PluggableTextMorph at the top should not indicate dirty state
Fixed. Tudor Girba-2 wrote
- Pressing up/down also moves the cursor in the top PluggableTextMorph. This should not happen.
This should be fixed now that you can't enter a new line Tudor Girba-2 wrote
- It would be interesting to have the count of hits even though we are only displaying a limited amount.
Yes it would. Feel free to submit code ;) Tudor Girba-2 wrote
And a question related to "Show all on down arrow when closed":
Ah, yes. I guess this is more relevant to entry completion, but if the completion menu is not yet open, and you press the down arrow while the text field has the keyboard focus, the menu will appear with all possible results. Keep the feedback coming!!! ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4733615.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Hi Sean, I just tested the new implementation. Exciting :). See below the comments and the little improvement for item count. [image: Inline image 1] But, now, we have another problem: going with up/down jumps over one items (so, you can only reach 1, 3, 5 ...). I could not figure out where the problem comes from. It only happens in the full Spotlight, but not in the completion example. On Thu, Jan 2, 2014 at 1:53 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
- I love it how I can navigate with up/down and still continue typing. This is seriously cool.
:)
Tudor Girba-2 wrote
- Esc has no effect (
I had implemented it for entry completion. It is working in SpotlighMorph now also.
Great. Works fine. Tudor Girba-2 wrote
- The list entries behave strangely because you use a text morph that can be edited. For example, type something, go with the mouse over an item in the list, you will see the cursor changes to a text one, click, and you can start typing there. Why not use a LabelMorph?
I didn't use LabelMorph because it deals with strings, not text, and I want to be able to e.g. make the matching substring bold like in the examples. But I locked the TextMorphs, so it's fixed.
Indeed. Got it. Tudor Girba-2 wrote
- Pressing Enter does not seem to trigger the action associated with a list. Only pressing double click seems to work. - The PluggableTextMorph at the top allows Enter. Pressing Enter leads to a line break. This is not wanted (you asked what I meant by it a field). - The PluggableTextMorph at the top should not indicate dirty state
Fixed.
Works. Tudor Girba-2 wrote
- Pressing up/down also moves the cursor in the top PluggableTextMorph. This should not happen.
This should be fixed now that you can't enter a new line
It's not fixed. Try this: - type ab - move down ==> all is fine: the search morph looks like (ab|) - move up ==> the cursor in the search morph moves at the beginning (|ab)
Tudor Girba-2 wrote
- It would be interesting to have the count of hits even though we are only displaying a limited amount.
Yes it would. Feel free to submit code ;)
Done. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; load
Tudor Girba-2 wrote
And a question related to "Show all on down arrow when closed":
Ah, yes. I guess this is more relevant to entry completion, but if the completion menu is not yet open, and you press the down arrow while the text field has the keyboard focus, the menu will appear with all possible results.
Aha. Got it.
Cheers, Doru
Keep the feedback coming!!!
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4733615.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
I love the item count - thanks. I saw the double jump too, but the cause wasn't obvious. And I see what you mean about the arrows; I'll look into it. I'm really enjoying the collaboration :) ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734023.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
I want this widget :) and behavior On 04 Jan 2014, at 02:53, Sean P. DeNigris <sean@clipperadams.com> wrote:
I love the item count - thanks. I saw the double jump too, but the cause wasn't obvious. And I see what you mean about the arrows; I'll look into it.
I'm really enjoying the collaboration :) Cheers, Sean
View this message in context: Re: Spotlight Demo Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Hi Sean, I enjoy the collaboration, too. It is really nice to have this energy invested in making cool widgets. We would need more of this :). I will try to look into the remaining issues, too. Let's continue synchronize over this thread. Cheers, Doru On Sat, Jan 4, 2014 at 2:53 AM, Sean P. DeNigris <sean@clipperadams.com>wrote:
I love the item count - thanks. I saw the double jump too, but the cause wasn't obvious. And I see what you mean about the arrows; I'll look into it.
I'm really enjoying the collaboration :) Cheers, Sean
------------------------------ View this message in context: Re: Spotlight Demo<http://forum.world.st/Spotlight-Demo-tp4733076p4734023.html>
Sent from the Pharo Smalltalk Developers mailing list archive<http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html>at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
On 04 Jan 2014, at 14:52, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi Sean,
I enjoy the collaboration, too. It is really nice to have this energy invested in making cool widgets. We would need more of this :).
+1
I will try to look into the remaining issues, too. Let's continue synchronize over this thread.
Cheers, Doru
On Sat, Jan 4, 2014 at 2:53 AM, Sean P. DeNigris <sean@clipperadams.com> wrote: I love the item count - thanks. I saw the double jump too, but the cause wasn't obvious. And I see what you mean about the arrows; I'll look into it.
I'm really enjoying the collaboration :) Cheers, Sean
View this message in context: Re: Spotlight Demo
Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
Tudor Girba-2 wrote
now, we have another problem: going with up/down jumps over one items (so, you can only reach 1, 3, 5 â¦) â¦
- Pressing up/down also moves the cursor in the top PluggableTextMorph. This should not happen.
Both were actually the same bug. I was not returning true to Morphic to say that we had handled the keystroke. They are now fixed and I integrated your item count changes too! ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734149.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want. As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...> ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
cool :) Stef On 04 Jan 2014, at 17:42, Sean P. DeNigris <sean@clipperadams.com> wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Look at those results! Can't wait to use it. Fantastic work Sean Questions: 1) how it behaves is you enter 'asStr' (and has tons of results because implementors of asString) 2) can you test a variation that in the implementor messages it shows you the class? (because lets say you type 'ope' for open, it will be several identical results from different classes) It will rock to have a way to type a couple of keystrokes then the arrow keys a couple of times and then enter to open a browser on the exact implementor you wanted. That will be ~5 keys strokes to browse anyone On Jan 4, 2014, at 2:42 PM, Sean P. DeNigris <sean@clipperadams.com> wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Thanks :) currently, it limits each group to show 7 results. And for messages, it opens an implementors browser, so #asString is only one result, no matter how many classes implement it. That being said, it is highly configurable. One could add a Methods group that does what I think you want... -------- Original message -------- From: "sebastian@flowingconcept.com [via Smalltalk]" <ml-node+s1294792n4734180h68@n4.nabble.com> Date: 01/04/2014 12:30 PM (GMT-05:00) To: "Sean P. DeNigris" <sean@clipperadams.com> Subject: Re: Spotlight Demo Look at those results! Can't wait to use it. Fantastic work Sean Questions: 1) how it behaves is you enter 'asStr' (and has tons of results because implementors of asString) 2) can you test a variation that in the implementor messages it shows you the class? (because lets say you type 'ope' for open, it will be several identical results from different classes) It will rock to have a way to type a couple of keystrokes then the arrow keys a couple of times and then enter to open a browser on the exact implementor you wanted. That will be ~5 keys strokes to browse anyone On Jan 4, 2014, at 2:42 PM, Sean P. DeNigris <[hidden email]> wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: Â *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
If you reply to this email, your message will be added to the discussion below: http://forum.world.st/Spotlight-Demo-tp4733076p4734180.html To unsubscribe from Spotlight Demo, click here. NAML ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734183.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
On Jan 4, 2014, at 4:06 PM, Sean P. DeNigris <sean@clipperadams.com> wrote:
Thanks :) currently, it limits each group to show 7 results. And for messages, it opens an implementors browser, so #asString is only one result, no matter how many classes implement it. That being said, it is highly configurable. One could add a Methods group that does what I think you want...
Get it. Clever. 7 is a great number as limit. Can't wait to have Pharo with that :D
Hi Sean, I just tested it. It works just great. First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier? Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion? Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you? Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail. Doru On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠< http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
Hi again, I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer I think this should be the design to follow for all morphs. I blogged about it in more details here: http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme... You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load In summary, something like: SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333). becomes: SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self And the default SpotterThemer says: SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333) What do you think? Cheers, Doru On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠< http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
Doru do you have a sketch (UML) to see how it works? Because indeed having a pattern for the theme is definitively important and Iâm sad that the same trick as the settings do not work for theme. Stef On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here: http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote: Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com> wrote: I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
I do not have a diagram now, but it is really trivial. It's not more than I said in the blog post. Is it not explicit enough? Doru On Mon, Jan 6, 2014 at 10:59 AM, Stéphane Ducasse <stephane.ducasse@inria.fr
wrote:
Doru
do you have a sketch (UML) to see how it works? Because indeed having a pattern for the theme is definitively important and Iâm sad that the same trick as the settings do not work for theme.
Stef
On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here:
http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠< http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
I will read it. I do not like the UITheme. I was more interested by the pattern. Stef On 06 Jan 2014, at 10:59, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
Doru
do you have a sketch (UML) to see how it works? Because indeed having a pattern for the theme is definitively important and Iâm sad that the same trick as the settings do not work for theme.
Stef
On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here: http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote: Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com> wrote: I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
I tried in latest 3.0 the example and I get a DNU error: 'Some code is setting text attributes length not matching the string size']. when I remove character. stef On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here: http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote: Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com> wrote: I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
Hi, I am not sure I understand. You tried to load Spotlight? And you got the error in Spotlight, or in any text? Cheers, Doru On Mon, Jan 6, 2014 at 4:47 PM, Stéphane Ducasse <stephane.ducasse@inria.fr>wrote:
I tried in latest 3.0 the example and I get a DNU
error: 'Some code is setting text attributes length not matching the string size'].
when I remove character.
stef
On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here:
http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠< http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
On 06 Jan 2014, at 17:24, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi,
I am not sure I understand. You tried to load Spotlight? And you got the error in Spotlight, or in any text?
sorry I had to run to catch a kid I did: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable then SpotlightCompletionExample open then type string and remove character by chracter and the last one crashes completely the system Stef
Cheers, Doru
On Mon, Jan 6, 2014 at 4:47 PM, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote: I tried in latest 3.0 the example and I get a DNU
error: 'Some code is setting text attributes length not matching the string size'].
when I remove character.
stef
On 06 Jan 2014, at 00:19, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi again,
I added a first shot at theming. The idea is simple: - we have one method in UITheme called spotterThemer that simply returns a SpotterThemer, and - all Spotter/Spotlight specific rendering methods are in SpotterThemer
I think this should be the design to follow for all morphs. I blogged about it in more details here: http://www.humane-assessment.com/blog/a-pharo-refactoring-story-adding-theme...
You can get the code from here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load
In summary, something like:
SpotlightItemMorph>>onSelected self color: (Color r: 0.2627 g: 0.4588 b: 0.9333).
becomes:
SpotlightItemMorph>>onSelected self theme spotterThemer configureSelectedItemMorph: self
And the default SpotterThemer says:
SpotterThemer>>configureSelectedItemMorph: aMorph aMorph color: (Color r: 0.2627 g: 0.4588 b: 0.9333)
What do you think?
Cheers, Doru
On Sun, Jan 5, 2014 at 9:26 AM, Tudor Girba <tudor@tudorgirba.com> wrote: Hi Sean,
I just tested it. It works just great.
First, would it be Ok with you to move the project to a more public place (like http://www.smalltalkhub.com/#!/~PharoExtras) so that others can contribute easier?
Second, I created a configuration with a development and stable version. You can find it here: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'ConfigurationOfSpotter'; load. (Smalltalk globals at: #ConfigurationOfSpotter) loadStable
And in the MetaRepoForPharo30 so that you can load it from the Configuration Browser. Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code. I will follow up on this in another mail.
Doru
On Sat, Jan 4, 2014 at 5:42 PM, Sean P. DeNigris <sean@clipperadams.com> wrote: I'm happy for now. As a general purpose completion option, I'd say we're officially at version 1.0. No obvious bugs, and provides the basic features I'd want.
As for replacing the existing Spotlight, I've decided to eat my own dog food and use the new tool in my images: *** n.b., if you load the Spotlight package now, it will override the global Spotlight shortcut
p.s. Steph, I added packages to the example for you ;) ⦠<http://forum.world.st/file/n4734153/Screen_Shot_2014-01-04_at_11.18.57_AM.pn...>
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734153.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com
"Every thing has its own flow"
Stéphane Ducasse wrote
then type string and remove character by chracter and the last one crashes completely the system
Thanks! Spotlight-SeanDeNigris.25 Fixed error when last character removed from text field e.g. by backspace. Thanks for Steph for the report. ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734780.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Ok I read UITheme would act as a theme factory. and each widget delegate to the Themer associated to themselve and the current theme So subclasse of UITheme can propose different themer for the same widget. Now since the themer is a separate class (from the morph it means that you must have all the hooks to customise it). So why not. I was also thinking that a widget could be an âabstractâ class whose subclasses implement the themes. Then you would create a widget like that SpolightItemMorph forThemer: UITheme blue and it would create an instance of a subclas SpotligherBluerItemMorph. Did you try this design? Stef
Now in the car I was thinking if each Widget acts as a factory and theme are subclasses. - each widget should have/inherit a factory system (may be not good) - to change a theme we will have to get instance of different widget subclasses (so it is not good). So I like the theme as strategy approach we should try on another widget. Stef
Ok I read
UITheme would act as a theme factory. and each widget delegate to the Themer associated to themselve and the current theme
So subclasse of UITheme can propose different themer for the same widget.
Now since the themer is a separate class (from the morph it means that you must have all the hooks to customise it). So why not. I was also thinking that a widget could be an âabstractâ class whose subclasses implement the themes.
Then you would create a widget like that
SpolightItemMorph forThemer: UITheme blue and it would create an instance of a subclas SpotligherBluerItemMorph.
Did you try this design?
Stef
Theming should be orthogonal to the widget, so subclassing isn't an option. But making it so isn't trivial either. However, instead of subclassing, each widget might have a theme, to which it could delegate it's rendering, or fallback to the default "theme" in case no custom theming has been defined. However, I favor "descriptive" theming (like CSS) rather than "programmed" theming (like the actual). Regards, Esteban A. Maringolo 2014/1/6 Stéphane Ducasse <stephane.ducasse@inria.fr>:
Now in the car I was thinking
if each Widget acts as a factory and theme are subclasses. - each widget should have/inherit a factory system (may be not good) - to change a theme we will have to get instance of different widget subclasses (so it is not good).
So I like the theme as strategy approach we should try on another widget.
Stef
Ok I read
UITheme would act as a theme factory. and each widget delegate to the Themer associated to themselve and the current theme
So subclasse of UITheme can propose different themer for the same widget.
Now since the themer is a separate class (from the morph it means that you must have all the hooks to customise it). So why not. I was also thinking that a widget could be an âabstractâ class whose subclasses implement the themes.
Then you would create a widget like that
SpolightItemMorph forThemer: UITheme blue and it would create an instance of a subclas SpotligherBluerItemMorph.
Did you try this design?
Stef
On Jan 6, 2014, at 3:40 PM, Esteban A. Maringolo <emaringolo@gmail.com> wrote:
However, I favor "descriptive" theming (like CSS) rather than "programmed" theming (like the actual).
this raises an interesting point and hard questions: if themes are programmed instead of easily described... Aren't they way more likely to end up being done as a second-class-citizen kind of task by a programmer instead of a first-class work of a focused designer? Do we have designer's feedback before we implement our UIs? If we do, do we listen? are we willing to?
Hi Stef, On Mon, Jan 6, 2014 at 5:54 PM, Stéphane Ducasse <stephane.ducasse@inria.fr>wrote:
Ok I read
UITheme would act as a theme factory. and each widget delegate to the Themer associated to themselve and the current theme
So subclasse of UITheme can propose different themer for the same widget.
Exactly.
Now since the themer is a separate class (from the morph it means that you must have all the hooks to customise it). So why not. I was also thinking that a widget could be an âabstractâ class whose subclasses implement the themes.
Then you would create a widget like that
SpolightItemMorph forThemer: UITheme blue and it would create an instance of a subclas SpotligherBluerItemMorph.
Did you try this design?
I think this is too convoluted because, like Estaban says, you want to keep the theming orthogonal with widget definition. But, you gave me an idea: If we implement in Morph the followings: Morph>>themer ^ themer ifNil: [self themerFor: self theme] Morph>>themerFor: aTheme ^ self subclassResponsibility And then in a morph we would have something like this: SpotlightItemMorph>>themerFor: aTheme ^ aTheme spotterThemer SpotlightItemMorph>>onSelected self themer configureSelectedItemMorph: self Then we could simply do pretty much what you want: SpotlightItemMorph new themer: MySpotterThemer new. I like this idea. What do you think? Doru Stef
-- www.tudorgirba.com "Every thing has its own flow"
I think this is too convoluted because, like Estaban says, you want to keep the theming orthogonal with widget definition.
Yes I do not like it either.
But, you gave me an idea:
If we implement in Morph the followings:
Morph>>themer ^ themer ifNil: [self themerFor: self theme]
what would be self theme I do not really like the idea to have all the morph talking to UITheme theme ^ UITheme current is not sexy to me
Morph>>themerFor: aTheme ^ self subclassResponsibility
And then in a morph we would have something like this:
SpotlightItemMorph>>themerFor: aTheme ^ aTheme spotterThemer
SpotlightItemMorph>>onSelected self themer configureSelectedItemMorph: self
Then we could simply do pretty much what you want:
SpotlightItemMorph new themer: MySpotterThemer new.
I like this idea. What do you think?
I do not know. Now what is clear is that we need strategy as in your original design. I was thinking about that too. Stef
Iâm experimenting with separate the widget from the skin⦠problem is sometimes theming is just change colors, but some others is widget building it self, so we will need widget factories (for theme), etc. all is doable, but all implies time :) On 07 Jan 2014, at 11:07, Stéphane Ducasse <Stephane.Ducasse@inria.fr> wrote:
I think this is too convoluted because, like Estaban says, you want to keep the theming orthogonal with widget definition.
Yes I do not like it either.
But, you gave me an idea:
If we implement in Morph the followings:
Morph>>themer ^ themer ifNil: [self themerFor: self theme]
what would be self theme I do not really like the idea to have all the morph talking to UITheme theme ^ UITheme current is not sexy to me
Morph>>themerFor: aTheme ^ self subclassResponsibility
And then in a morph we would have something like this:
SpotlightItemMorph>>themerFor: aTheme ^ aTheme spotterThemer
SpotlightItemMorph>>onSelected self themer configureSelectedItemMorph: self
Then we could simply do pretty much what you want:
SpotlightItemMorph new themer: MySpotterThemer new.
I like this idea. What do you think?
I do not know. Now what is clear is that we need strategy as in your original design. I was thinking about that too.
Stef
Maybe widgets should delegate to the theme the rendering? So Morph subclass: Widget. "So this applies only for widget morphs?" Widget subclass: List. List >> drawOn: aCanvas self theme drawList: self onCanvas: aCanvas And then each theme can really render different each widget. On Tue, Jan 7, 2014 at 11:10 AM, Esteban Lorenzano <estebanlm@gmail.com>wrote:
Iâm experimenting with separate the widget from the skin⦠problem is sometimes theming is just change colors, but some others is widget building it self, so we will need widget factories (for theme), etc.
all is doable, but all implies time :)
On 07 Jan 2014, at 11:07, Stéphane Ducasse <Stephane.Ducasse@inria.fr> wrote:
I think this is too convoluted because, like Estaban says, you want to keep the theming orthogonal with widget definition.
Yes I do not like it either.
But, you gave me an idea:
If we implement in Morph the followings:
Morph>>themer ^ themer ifNil: [self themerFor: self theme]
what would be self theme I do not really like the idea to have all the morph talking to UITheme theme ^ UITheme current is not sexy to me
Morph>>themerFor: aTheme ^ self subclassResponsibility
And then in a morph we would have something like this:
SpotlightItemMorph>>themerFor: aTheme ^ aTheme spotterThemer
SpotlightItemMorph>>onSelected self themer configureSelectedItemMorph: self
Then we could simply do pretty much what you want:
SpotlightItemMorph new themer: MySpotterThemer new.
I like this idea. What do you think?
I do not know. Now what is clear is that we need strategy as in your original design. I was thinking about that too.
Stef
2014/1/7 Guillermo Polito <guillermopolito@gmail.com>:
Maybe widgets should delegate to the theme the rendering?
That's what I proposed a few mails ago to Stef. But you'll end up with a parallel hierarchy for each theme, with a class for each widget rendered. It is better than having everything coupled in the widget itself, but somehow it smells bad to me. There MUST BE another solution. Esteban A. Maringolo
Tudor Girba-2 wrote
First, would it be Ok with you to move the project to a more public place
Great, whereever you think... Tudor Girba-2 wrote
Second, I created a configuration with a development and stable version.
Cool, thanks :) Tudor Girba-2 wrote
Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
I would prefer ConfigurationOfNewSpotlight or ConfigurationOfSpotlight2. Spotlight is what we are modeling, and introducing a new term will I think generate more confusion (i.e. "what the heck is a Spotter" vs. "oh, cool, just like the Mac Spotlight that I already use"). Tudor Girba-2 wrote
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
I guess as a compromise I can just extract the shortcut into another package, so the default will not integrate with the system, and loading the additional package will. For me, I want this widget to come up on shift + cr. Tudor Girba-2 wrote
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code.
This is exciting. I found Polymorph / Themes to be very confusing. I welcome another look at this. ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734781.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
for me, thatâs the new spotlight, and should replace the old one (in Pharo 4)⦠so +1 for âSpotlight2â :) On 07 Jan 2014, at 04:32, Sean P. DeNigris <sean@clipperadams.com> wrote:
Tudor Girba-2 wrote
First, would it be Ok with you to move the project to a more public place
Great, whereever you think...
Tudor Girba-2 wrote
Second, I created a configuration with a development and stable version.
Cool, thanks :)
Tudor Girba-2 wrote
Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
I would prefer ConfigurationOfNewSpotlight or ConfigurationOfSpotlight2. Spotlight is what we are modeling, and introducing a new term will I think generate more confusion (i.e. "what the heck is a Spotter" vs. "oh, cool, just like the Mac Spotlight that I already use").
Tudor Girba-2 wrote
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
I guess as a compromise I can just extract the shortcut into another package, so the default will not integrate with the system, and loading the additional package will. For me, I want this widget to come up on shift + cr.
Tudor Girba-2 wrote
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code.
This is exciting. I found Polymorph / Themes to be very confusing. I welcome another look at this.
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734781.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Ok. I am renaming it and will publish it in PharoExtras. Doru On Tue, Jan 7, 2014 at 9:59 AM, Esteban Lorenzano <estebanlm@gmail.com>wrote:
for me, thatâs the new spotlight, and should replace the old one (in Pharo 4)⦠so +1 for âSpotlight2â :)
On 07 Jan 2014, at 04:32, Sean P. DeNigris <sean@clipperadams.com> wrote:
Tudor Girba-2 wrote
First, would it be Ok with you to move the project to a more public place
Great, whereever you think...
Tudor Girba-2 wrote
Second, I created a configuration with a development and stable version.
Cool, thanks :)
Tudor Girba-2 wrote
Please note that I named the configuration Spotter, because there already exists a ConfigurationOfSpotlight for the widget of Esteban. Would it be Ok to change the name of the classes, too, to avoid confusion?
I would prefer ConfigurationOfNewSpotlight or ConfigurationOfSpotlight2. Spotlight is what we are modeling, and introducing a new term will I think generate more confusion (i.e. "what the heck is a Spotter" vs. "oh, cool, just like the Mac Spotlight that I already use").
Tudor Girba-2 wrote
Third, I think we should not mix the morph with the global shortcut. I understand this is convenient, but these should pretty much be different projects. Is that Ok with you?
I guess as a compromise I can just extract the shortcut into another package, so the default will not integrate with the system, and loading the additional package will. For me, I want this widget to come up on shift + cr.
Tudor Girba-2 wrote
Fourth, I would like to theme this morph, too :). With this occasion, I would like to try a slightly different design for handling the theme code.
This is exciting. I found Polymorph / Themes to be very confusing. I welcome another look at this.
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734781.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
Ok. I am renaming it and will publish it in PharoExtras.
Thanks. I just loaded it. There is a problem. It flattened the package, removing all my sub-categories/tags/whatever-we're-calling-them. Also, I don't think it is necessary to rename the package and all the classes as there is no name conflict with Esteban's. Although maybe I'm missing something. What do you think? I'm going to continue to commit to the old package until we get this sorted out. ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734989.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Hi, Please wait before going on :). I published a Spotlight2 (renamed package and classes) in PharoExtras together with a development configuration. Please use this one. You can load it from: Gofer new smalltalkhubUser: 'PharoExtras' project: 'Spotlight2'; package: 'ConfigurationOfSpotlight2'; load. (Smalltalk globals at: #ConfigurationOfSpotlight2) loadDevelopment. I just noticed that indeed, the tags are gone. I have no idea why, but I suspect it has to do with the refactoring I did. I will fix the categories tomorrow. Cheers, Doru On Tue, Jan 7, 2014 at 7:24 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
Ok. I am renaming it and will publish it in PharoExtras.
Thanks. I just loaded it. There is a problem. It flattened the package, removing all my sub-categories/tags/whatever-we're-calling-them.
Also, I don't think it is necessary to rename the package and all the classes as there is no name conflict with Esteban's. Although maybe I'm missing something. What do you think?
I'm going to continue to commit to the old package until we get this sorted out.
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734989.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
I added the categories now. Doru On Tue, Jan 7, 2014 at 9:49 PM, Tudor Girba <tudor@tudorgirba.com> wrote:
Hi,
Please wait before going on :). I published a Spotlight2 (renamed package and classes) in PharoExtras together with a development configuration. Please use this one.
You can load it from:
Gofer new smalltalkhubUser: 'PharoExtras' project: 'Spotlight2'; package: 'ConfigurationOfSpotlight2'; load. (Smalltalk globals at: #ConfigurationOfSpotlight2) loadDevelopment.
I just noticed that indeed, the tags are gone. I have no idea why, but I suspect it has to do with the refactoring I did. I will fix the categories tomorrow.
Cheers, Doru
On Tue, Jan 7, 2014 at 7:24 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
Ok. I am renaming it and will publish it in PharoExtras.
Thanks. I just loaded it. There is a problem. It flattened the package, removing all my sub-categories/tags/whatever-we're-calling-them.
Also, I don't think it is necessary to rename the package and all the classes as there is no name conflict with Esteban's. Although maybe I'm missing something. What do you think?
I'm going to continue to commit to the old package until we get this sorted out.
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4734989.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com
"Every thing has its own flow"
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
I added the categories now.
Ugh, you're too fast ;) I already had made several commits to the old package. I'll try to merge into the new one⦠Thanks for all the help!! ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735029.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
No. Thank you for the great contribution :). Seriously, this is fun. And now I am curious about the ActiveTutor :). Is the idea to provide contextual help for every morph? Cheers, Doru On Tue, Jan 7, 2014 at 11:12 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
I added the categories now.
Ugh, you're too fast ;) I already had made several commits to the old package. I'll try to merge into the new oneâ¦
Thanks for all the help!!
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735029.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
Seriously, this is fun. And now I am curious about the ActiveTutor :). Is the idea to provide contextual help for every morph?
Ha ha, you caught me. I wasn't going to mention it until it was further along, but here's a first cut... https://vimeo.com/83655001 (the video will be available in ~45 minutes) ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735073.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Exciting! Doru On Wed, Jan 8, 2014 at 7:10 AM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
Seriously, this is fun. And now I am curious about the ActiveTutor :). Is the idea to provide contextual help for every morph?
Ha ha, you caught me. I wasn't going to mention it until it was further along, but here's a first cut...
https://vimeo.com/83655001 (the video will be available in ~45 minutes)
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735073.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
I added the categories now.
What version of the original Spotlight package did you port, so I can merge my changes... ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735281.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
I started at Spotlight-SeanDeNigris.25, and then I added some more code about the themer, so, it is Spotlight-TudorGirba.27 from: Gofer new smalltalkhubUser: 'girba' project: 'GPlay'; package: 'Spotlight'; disablePackageCache; load Doru On Wed, Jan 8, 2014 at 11:13 PM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Tudor Girba-2 wrote
I added the categories now.
What version of the original Spotlight package did you port, so I can merge my changes...
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735281.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
Tudor Girba-2 wrote
I started at Spotlight-SeanDeNigris.25, and then I added some more code
Merged. The project depends on ActiveTutor now. A small part of ActiveTutor depends on Spotlight, but I can't seem to split the ActiveTutor package. I have ActiveTutor with tags ActiveTutor-Core and ActiveTutor-Screencasts, but the old "delete the working copy, then create MC packages for the sub-categories" doesn't seem to work in 3.0. I deleted the working copy, but when I add the MC packages for ActiveTutor-Core and ActiveTutor-Screencasts, they are empty :( ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735284.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Sean P. DeNigris wrote
Merged. The project depends on ActiveTutor now
I fixed the dependencies and committed a new configuration ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735304.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Excellent. I will take a look in the coming today or tomorrow. Doru On Thu, Jan 9, 2014 at 5:22 AM, Sean P. DeNigris <sean@clipperadams.com>wrote:
Sean P. DeNigris wrote
Merged. The project depends on ActiveTutor now
I fixed the dependencies and committed a new configuration
----- Cheers, Sean -- View this message in context: http://forum.world.st/Spotlight-Demo-tp4733076p4735304.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
-- www.tudorgirba.com "Every thing has its own flow"
participants (8)
-
DeNigris Sean -
Esteban A. Maringolo -
Esteban Lorenzano -
Guillermo Polito -
Sean P. DeNigris -
Sebastian Sastre -
Stéphane Ducasse -
Tudor Girba