Mercurial > hg > svgui
comparison layer/Layer.h @ 180:29f01de27db4
* Add vertical zooming and snap-to-selection for OSC control;
add a demo script
author | Chris Cannam |
---|---|
date | Wed, 15 Nov 2006 18:22:26 +0000 |
parents | 10a82b2bbb8b |
children | 42118892f428 |
comparison
equal
deleted
inserted
replaced
179:6a0d54f3f21a | 180:29f01de27db4 |
---|---|
125 * false) otherwise. SnapNeighbouring should always choose the | 125 * false) otherwise. SnapNeighbouring should always choose the |
126 * same feature that would be used in an editing operation through | 126 * same feature that would be used in an editing operation through |
127 * calls to editStart etc. | 127 * calls to editStart etc. |
128 * | 128 * |
129 * Return true if a suitable feature was found and frame adjusted | 129 * Return true if a suitable feature was found and frame adjusted |
130 * accordingly. Return false if no suitable feature was | 130 * accordingly. Return false if no suitable feature was available |
131 * available. Also return the resolution of the model in this | 131 * (and leave frame unmodified). Also return the resolution of |
132 * layer in sample frames. | 132 * the model in this layer in sample frames. |
133 */ | 133 */ |
134 virtual bool snapToFeatureFrame(View * /* v */, | 134 virtual bool snapToFeatureFrame(View * /* v */, |
135 int & /* frame */, | 135 int & /* frame */, |
136 size_t &resolution, | 136 size_t &resolution, |
137 SnapType /* snap */) const { | 137 SnapType /* snap */) const { |
299 /** | 299 /** |
300 * Get the number of vertical zoom steps available for this layer. | 300 * Get the number of vertical zoom steps available for this layer. |
301 * If vertical zooming is not available, return 0. The meaning of | 301 * If vertical zooming is not available, return 0. The meaning of |
302 * "zooming" is entirely up to the layer -- changing the zoom | 302 * "zooming" is entirely up to the layer -- changing the zoom |
303 * level may cause the layer to reset its display extents or | 303 * level may cause the layer to reset its display extents or |
304 * change another property such as display gain. | 304 * change another property such as display gain. However, layers |
305 * are advised for consistency to treat smaller zoom steps as | |
306 * "more distant" or "zoomed out" and larger ones as "closer" or | |
307 * "zoomed in". | |
308 * | |
305 * Layers that provide this facility should also emit the | 309 * Layers that provide this facility should also emit the |
306 * verticalZoomChanged signal if their vertical zoom changes | 310 * verticalZoomChanged signal if their vertical zoom changes |
307 * due to factors other than setVerticalZoomStep being called. | 311 * due to factors other than setVerticalZoomStep being called. |
308 */ | 312 */ |
309 virtual int getVerticalZoomSteps(int &defaultStep) const { return 0; } | 313 virtual int getVerticalZoomSteps(int &defaultStep) const { return 0; } |