The Artima Developer Community
Sponsored Link

Agile Buzz Forum
Test Feedback back for Packages

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
James Robertson

Posts: 29924
Nickname: jarober61
Registered: Jun, 2003

David Buck, Smalltalker at large
Test Feedback back for Packages Posted: Oct 11, 2005 4:52 PM
Reply to this message Reply

This post originated from an RSS feed registered with Agile Buzz by James Robertson.
Original Post: Test Feedback back for Packages
Feed Title: Travis Griggs - Blog
Feed URL: http://www.cincomsmalltalk.com/rssBlog/travis-rss.xml
Feed Description: This TAG Line is Extra
Latest Agile Buzz Posts
Latest Agile Buzz Posts by James Robertson
Latest Posts From Travis Griggs - Blog

Advertisement

In yesterday's post about test feedback for packages, one of the things I listed as issues was that ...Different size icons make the vertical alignment sketchy....

So I sat down and tried to figure out how to make it put the icon at the back. One of the problems is that there's implicit notion that your list is text, with an optional icon on the left side. These means we'd need a new kind of LabelAndEndingIcon or something. And we'd have to get the lists to use a visualBlock, instead of a displayStringSelector. And figure out where to wire that in. It's all in there, but you'd touch stuff everywhere.

Luck is our lady in this case. If you make displayString return a Text object rather than a String for PackageModel, the list will happily go with that. This is cool. You could italicize package names. Or bold them. Or superscript them. And do all kinds of cute formatting. You could make your browser look just like those Christmas letters we used to get from Mac owners in the 80's... you know, the one's where the font changed every 2 or 3 sentences. Just because, well, because it could. It was the trademark of the Mac letter writer, his or her way of saying "Nah nah nah nah, I own a Mac and you don't." But I digress.

Rather than go nuts with fonts, I just chose to use a #trailingInsert emphasis. This allows you to insert arbitrary graphics in the text stream. It's counterpart, #leadingInsert is what is used to put the Stop Sign in for PDP breakpoints. This is possible when you load the package ExtraEmphases. With that in place, we get something that looks like this:

Package List with Test Icons

Doing it this way has another interesting side affect. You know how when you flip to the "Heirarchy Mode" for a class, the Packages in the second list over, don't show the icon decoration that they would have otherwise? Not a problem in this case. The test status still shows up. It would be interesting to respin the package/bundle modified/notmodified icons this way, using ExtraEmphases #insertLeading, rather than LabelAndIcon. Then it would just work everywhere.

Oh yeah, I took out the ability for Bundles to show the test status icon. I don't use Bundles; if this disavows someone, let me know, I'll figure out how to put them back in.

Read: Test Feedback back for Packages

Topic: Smalltalk for Java developers Previous Topic   Next Topic Topic: Volume does matter

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use