Added WIP support for affine transformations to BViews.
Everything untested, but compiles, so it must work. The idea is to introduce BAffineTransform additionally to the existing Origin and Scale properties of BViews. One may use it in parallel or as an alternative. Painter in app_server is not yet aware of the additional transformation. It is however already used to transform drawing coordinates. It probably needs to work differently, perhaps only in Painter and AGGTextRenderer.
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#define _VIEW_H
|
||||
|
||||
|
||||
#include <AffineTransform.h>
|
||||
#include <Alignment.h>
|
||||
#include <Font.h>
|
||||
#include <Handler.h>
|
||||
@@ -285,6 +286,12 @@ public:
|
||||
void SetOrigin(float x, float y);
|
||||
BPoint Origin() const;
|
||||
|
||||
// Works in addition to Origin and Scale.
|
||||
// May be used in parallel or as a much
|
||||
// more powerful alternative.
|
||||
void SetTransform(BAffineTransform transform);
|
||||
BAffineTransform Transform() const;
|
||||
|
||||
void PushState();
|
||||
void PopState();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user