Scroom 0.14-48-ga0fee447
Loading...
Searching...
No Matches
transformpresentation.cc File Reference
#include <string>
#include <utility>
#include <cairo.h>
#include <scroom/color.hh>
#include <scroom/colormappable.hh>
#include <scroom/pipettelayeroperations.hh>
#include <scroom/pipetteviewinterface.hh>
#include <scroom/point.hh>
#include <scroom/presentationinterface.hh>
#include <scroom/rectangle.hh>
#include <scroom/transformpresentation.hh>
#include <scroom/viewinterface.hh>
#include "scroom/cairo-helpers.hh"
#include "scroom/tweak-view.hh"
Include dependency graph for transformpresentation.cc:

Namespaces

namespace  Detail
 

Functions

Scroom::Utils::Point< double > getAspectRatio (const PresentationInterface::Ptr &presentation)
 

Function Documentation

◆ getAspectRatio()

Scroom::Utils::Point< double > getAspectRatio ( const PresentationInterface::Ptr presentation)
163{
164 return try_get<TransformationData::Ptr>(presentation->getContext())
165 .transform([](const auto& td) { return td->getAspectRatio(); })
166 .value_or(Scroom::Utils::make_point(1.0, 1.0));
167}
Point< T > make_point(T x, T y)
Definition point.hh:116

Referenced by PipetteHandler::computeValues(), and MeasureHandler::displayMeasurement().

Here is the call graph for this function:
Here is the caller graph for this function: