shoes/shoes4 — pull request #898 by KCErb (2014-09-26 17:08:39+00:00)
Title: Style Module Specs

Hi all,

I added some specs to the style module. The only things I could think to spec (in addition to what is in #871) is that `Common::Style` needs to set dimensions and click differently from other properties.

**Why dimensions are special**
Most of an element's visual properties (stroke, checked? etc) are sitting in the style hash. So once `udpate_style` gets called the gui updates from that hash and the object gets updated. But the gui doesn't look at an element's style hash to position it. It looks at the element's `@dimensions` object. So if a new dimension gets passed via style, that information needs to get passed onto the `@dimensions` object.

**Why click is special**
Clickable element's include the 'clickable' module which gives them a 'click' method. That method in turn passes proc's on to the gui for setting up click listeners. If a new click proc gets passed into the style method, and `update_style` gets called, the gui update from `redrawing_aspect` won't be enough to make sure that a new listener gets created and the old one destroyed. For this reason, style need to pass the proc onto `Common::Clickable#click` for proper handling.

Do you see anything else in the style module that needs to be spec'd? If not, this is ready to ship imho.