summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorArmin Le Grand <Armin.Le.Grand@cib.de>2017-11-02 18:28:04 +0100
committerArmin Le Grand <Armin.Le.Grand@cib.de>2017-11-18 13:07:43 +0100
commit6675e6eaf999de94d49d7644d5877537fda83239 (patch)
tree588b33264a822271d2840d7d9c39dc31212f642e /include
parent995c75de956436606e4f313d60257285955586d8 (diff)
RotateFlyFrame3: Initial support added
First steps to get a rotated FlyFrame and content that only uses layouted sizes/positions and does not change the model data (except rotation). This works with persistence, after reload the rotation can be resetted with going back to the original FrameSize. Lot of stuff not yet working, experimental state. Change-Id: Ie29d501fe2e618a1cb4457d600ce97575ed372d0
Diffstat (limited to 'include')
-rw-r--r--include/basegfx/numeric/ftools.hxx20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/basegfx/numeric/ftools.hxx b/include/basegfx/numeric/ftools.hxx
index 19e8e101987c..eb030b2530d1 100644
--- a/include/basegfx/numeric/ftools.hxx
+++ b/include/basegfx/numeric/ftools.hxx
@@ -152,6 +152,26 @@ namespace basegfx
*/
BASEGFX_DLLPUBLIC double snapToNearestMultiple(double v, const double fStep);
+ /** RotateFlyFrame3: Normalize to range defined by [0.0 ... fRange[, independent
+ if v is positive or negative.
+
+ Examples:
+
+ normalizeToRange(0.5, -1.0) = 0.0
+ normalizeToRange(0.5, 0.0) = 0.0
+ normalizeToRange(0.5, 1.0) = 0.5
+ normalizeToRange(-0.5, 1.0) = 0.5
+ normalizeToRange(-0.3, 1.0) = 0.7
+ normalizeToRange(-0.7, 1.0) = 0.3
+ normalizeToRange(3.5, 1.0) = 0.5
+ normalizeToRange(3.3, 1.0) = 0.3
+ normalizeToRange(3.7, 1.0) = 0.7
+ normalizeToRange(-3.5, 1.0) = 0.5
+ normalizeToRange(-3.3, 1.0) = 0.7
+ normalizeToRange(-3.7, 1.0) = 0.3
+ */
+ BASEGFX_DLLPUBLIC double normalizeToRange(double v, const double fRange);
+
class BASEGFX_DLLPUBLIC fTools
{
public: