11#ifndef __AUDACITY_ZOOM_INFO__
12#define __AUDACITY_ZOOM_INFO__
49 ZoomInfo(
double start,
double pixelsPerSecond);
72 double PositionToTime(wxInt64 position,
74 ,
bool ignoreFisheye =
false
81 wxInt64 TimeToPosition(
double time,
83 ,
bool ignoreFisheye =
false
88 double TimeRangeToPixelWidth(
double timeRange)
const;
92 return PositionToTime(offset + TimeToPosition(time, ignoreFisheye), ignoreFisheye);
104 {
return GetVRulerOffset() + GetVRulerWidth() + 1; }
109 std::max( 0, GetWidth() - ( GetLeftOffset() +
kRightMargin ) );
116 auto width = GetTracksUsableWidth();
117 return PositionToTime(width, 0,
true);
120 bool ZoomInAvailable()
const;
121 bool ZoomOutAvailable()
const;
124 {
return 44100.0 / 512.0; }
128 void SetZoom(
double pixelsPerSecond);
132 double GetZoom()
const;
134 static double GetMaxZoom( );
135 static double GetMinZoom( );
139 void ZoomBy(
double multiplier);
144 : position(p), averageZoom(z), inFisheye(i) {}
156 (
double rate,
Intervals &results, wxInt64 width, wxInt64 origin = 0)
const;
169 bool InFisheye(wxInt64 , wxInt64 WXUNUSED(origin = 0))
const
181 int mVRulerWidth{ 36 };
Utility ClientData::Site to register hooks into a host class that attach client data.
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
A listener notified of changes in preferences.
static double GetDefaultZoom()
bool InFisheye(wxInt64, wxInt64 WXUNUSED(origin=0)) const
wxInt64 GetFisheyeRightBoundary(wxInt64 WXUNUSED(origin=0)) const
std::vector< Interval > Intervals
double GetScreenEndTime() const
int GetVRulerOffset() const
ZoomInfo(const ZoomInfo &) PROHIBITED
void SetVRulerWidth(int width)
int GetLeftOffset() const
int GetTracksUsableWidth() const
wxInt64 GetFisheyeLeftBoundary(wxInt64 WXUNUSED(origin=0)) const
double OffsetTimeByPixels(double time, wxInt64 offset, bool ignoreFisheye=false) const
int GetVRulerWidth() const
FisheyeState GetFisheyeState() const
AUDACITY_DLL_API void UpdatePrefs(wxWindow *pParent)
A convenient default parameter for class template Site.
Interval(wxInt64 p, double z, bool i)