If a layer has the "width" hint set, but has no "width" parameter, scale the width...
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 15 Feb 2008 13:55:52 +0000 (13:55 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 15 Feb 2008 13:55:52 +0000 (13:55 +0000)
git-svn-id: http://svn.voria.com/code@1698 1f10aa63-cdf2-0310-b900-c93c546f37ac

synfig-studio/trunk/src/gtkmm/duckmatic.cpp

index b470816..8475e06 100644 (file)
@@ -1534,6 +1534,9 @@ Duckmatic::add_to_ducks(const synfigapp::ValueDesc& value_desc,etl::handle<Canva
                                                        ValueBase value(synfigapp::ValueDesc(value_desc.get_layer(),param_desc->get_hint()).get_value(get_time()));
                                                        if(value.same_type_as(synfig::Real()))
                                                                width->set_scalar(value.get(synfig::Real())*0.5f);
+                                                       // if it doesn't have a "width" parameter, scale by 0.5f instead
+                                                       else
+                                                               width->set_scalar(0.5f);
                                                }
                                                // otherwise just present the raw unscaled width
                                                else