19#include <Cocoa/Cocoa.h>
85 "Execute, gVirtualX is either null or not of TGCocoa type");
95 assert(
segments != 0 &&
"DrawSegments, segments parameter is null");
105 "Execute, gVirtualX is either null or not of TGCocoa type");
121 "Execute, gVirtualX is either null or not of TGCocoa type");
139 return fID == drawable ||
fSrc == drawable ||
fGC.fClipMask == drawable;
146 "Execute, gVirtualX is either null or not of TGCocoa type");
155 const std::string &
text)
166 "Execute, gVirtualX is either null or not of TGCocoa type");
176 fRectangle(rectangle)
184 "Execute, gVirtualX is either null or not of TGCocoa type");
196 assert(
points != 0 &&
"FillPolygon, points parameter is null");
206 "Execute, gVirtualX is either null or not of TGCocoa type");
215 fRectangle(rectangle)
223 "Execute, gVirtualX is either null or not of TGCocoa type");
235 assert(
view !=
nil &&
"UpdateWindow, view parameter is nil");
258 "Execute, gVirtualX is either null or not of TGCocoa type");
282 return NSPoint{CGFloat(
rp.fX), CGFloat(
rp.fY)};
288 assert(ctx &&
"Execute, 'ctx' parameter is nullptr");
313 assert(ctx &&
"Execute, invalid (nullptr) parameter 'ctx'");
317 for (
auto &point :
line) {
349 }
catch (
const std::exception &) {
358 assert(
segments != 0 &&
"AddDrawSegments, segments parameter is null");
365 }
catch (
const std::exception &) {
382 }
catch (
const std::exception &) {
402 }
catch (
const std::exception &) {
418 }
catch (
const std::exception &) {
436 }
catch (
const std::exception &) {
454 }
catch (
const std::exception &) {
463 assert(
polygon != 0 &&
"AddFillPolygon, polygon parameter is null");
470 }
catch (
const std::exception &) {
478 assert(view !=
nil &&
"AddUpdateWindow, view parameter is nil");
481 std::unique_ptr<UpdateWindow> cmd(
new UpdateWindow(view));
484 }
catch (
const std::exception &) {
496 }
catch (
const std::exception &) {
508 }
catch (
const std::exception &) {
520 }
catch (
const std::exception &) {
528 assert(
impl != 0 &&
"Flush, impl parameter is null");
544 if (drawable.fIsPixmap) {
591 }
catch (
const std::exception &) {
621 assert(
impl != 0 &&
"FlushXOROps, impl parameter is null");
625 "FlushXOROps, drawable must be of type QuartzView");
632 ::Warning(
"FlushXOROps",
"No XorDrawingWindow found to draw into");
710 if (
r2.origin.x >=
r1.origin.x +
r1.size.width)
712 if (
r2.origin.x +
r2.size.width <=
r1.origin.x)
714 if (
r2.origin.y >=
r1.origin.y +
r1.size.height)
716 if (
r2.origin.y +
r2.size.height <=
r1.origin.y)
740 assert(view !=
nil &&
"ClipOverlaps, view parameter is nil");
742 typedef std::vector<QuartzView *>::reverse_iterator reverse_iterator;
838 if (!
recIt->size.width && !
recIt->size.height) {
861 assert(it != last && (it == first || *it ==
value) &&
"internal logic error");
864 return it == first && *it !=
value ? last : it;
874 assert((it == last || *it ==
value) &&
"internal logic error");
Handle_t Pixmap_t
Pixmap handle.
Handle_t Window_t
Window handle.
Handle_t Drawable_t
Drawable handle.
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize wid
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t r
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t rect
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t child
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t CopyArea
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char FillPolygon
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t UChar_t len
Option_t Option_t TPoint TPoint const char x2
Option_t Option_t TPoint TPoint const char x1
Option_t Option_t TPoint TPoint const char y2
Option_t Option_t TPoint TPoint const char DrawLine
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t FillRectangle
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t points
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t src
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t height
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void gc
Option_t Option_t TPoint TPoint const char text
Option_t Option_t TPoint TPoint const char y1
ClearArea(Window_t wid, const Rectangle_t &area)
void RemoveXORGraphicsOperationsForWindow(Window_t wid)
void AddDrawBoxXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2)
std::vector< WidgetRect > fRectsToClip
std::vector< CGRect > fClippedRegion
std::vector< Command * > fXorOps
std::vector< bool > fGrid
void AddDrawLineXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2)
void Flush(Details::CocoaPrivate *impl)
void AddDrawSegments(Drawable_t wid, const GCValues_t &gc, const Segment_t *segments, Int_t nSegments)
void AddFillPolygon(Drawable_t wid, const GCValues_t &gc, const Point_t *polygon, Int_t nPoints)
void FlushXOROps(Details::CocoaPrivate *impl)
void ClipOverlaps(QuartzView *view)
std::vector< QuartzView * > fViewBranch
void RemoveGraphicsOperationsForWindow(Window_t wid)
void AddClearArea(Window_t wid, Int_t x, Int_t y, UInt_t w, UInt_t h)
std::vector< int > fYBounds
void AddDrawRectangle(Drawable_t wid, const GCValues_t &gc, Int_t x, Int_t y, UInt_t w, UInt_t h)
void ClearXOROperations()
void AddDrawLine(Drawable_t wid, const GCValues_t &gc, Int_t x1, Int_t y1, Int_t x2, Int_t y2)
void RemoveOperationsForDrawable(Drawable_t wid)
std::vector< Command * >::size_type size_type
void AddDrawString(Drawable_t wid, const GCValues_t &gc, Int_t x, Int_t y, const char *text, Int_t len)
void AddDeletePixmap(Pixmap_t pixmap)
std::vector< Command * > fCommands
std::vector< int > fXBounds
void AddCopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, Int_t srcX, Int_t srcY, UInt_t width, UInt_t height, Int_t dstX, Int_t dstY)
void AddUpdateWindow(QuartzView *view)
void BuildClipRegion(const WidgetRect &rect)
void AddFillRectangle(Drawable_t wid, const GCValues_t &gc, Int_t x, Int_t y, UInt_t w, UInt_t h)
virtual bool IsGraphicsCommand() const
virtual void Execute() const =0
virtual bool HasOperand(Drawable_t drawable) const
bool HasOperand(Drawable_t drawable) const
CopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, const Rectangle_t &area, const Point &dstPoint)
DeletePixmap(Pixmap_t pixmap)
DrawBoxXor(Window_t windowID, const Point &p1, const Point &p2)
DrawLineXor(Window_t windowID, const Point &p1, const Point &p2)
DrawLine(Drawable_t wid, const GCValues_t &gc, const Point &p1, const Point &p2)
DrawRectangle(Drawable_t wid, const GCValues_t &gc, const Rectangle_t &rectangle)
std::vector< Segment_t > fSegments
DrawSegments(Drawable_t wid, const GCValues_t &gc, const Segment_t *segments, Int_t nSegments)
DrawString(Drawable_t wid, const GCValues_t &gc, const Point &point, const std::string &text)
std::vector< Point_t > fPolygon
FillPolygon(Drawable_t wid, const GCValues_t &gc, const Point_t *points, Int_t nPoints)
const Rectangle_t fRectangle
FillRectangle(Drawable_t wid, const GCValues_t &gc, const Rectangle_t &rectangle)
UpdateWindow(QuartzView *view)
const_iterator begin() const
const_iterator end() const
This class implements TVirtualX interface for MacOS X, using Cocoa and Quartz 2D.
QuartzPixmap * fBackBuffer
QuartzWindow * fQuartzWindow
QuartzImage * fShapeCombineMask
void ClipToShapeMask(NSView< X11Window > *view, CGContextRef ctx)
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
Graphics context structure.
Point structure (maps to the X11 XPoint structure)
Rectangle structure (maps to the X11 XRectangle structure)
Used for drawing line segments (maps to the X11 XSegments structure)