qwt_clipper.h 917 B

123456789101112131415161718192021222324252627282930313233343536
  1. /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
  2. * Qwt Widget Library
  3. * Copyright (C) 1997 Josef Wilgen
  4. * Copyright (C) 2002 Uwe Rathmann
  5. *
  6. * This library is free software; you can redistribute it and/or
  7. * modify it under the terms of the Qwt License, Version 1.0
  8. *****************************************************************************/
  9. #ifndef QWT_CLIPPER_H
  10. #define QWT_CLIPPER_H
  11. #include "qwt_global.h"
  12. #include "qwt_interval.h"
  13. #include <qpolygon.h>
  14. #include <qvector.h>
  15. class QRect;
  16. class QRectF;
  17. /*!
  18. \brief Some clipping algos
  19. */
  20. class QWT_EXPORT QwtClipper
  21. {
  22. public:
  23. static QPolygon clipPolygon( const QRect &, const QPolygon & );
  24. static QPolygonF clipPolygonF( const QRectF &, const QPolygonF & );
  25. static QVector<QwtInterval> clipCircle(
  26. const QRectF &, const QPointF &, double radius );
  27. };
  28. #endif