From ace68ca10479e95f72be49ff3106ebdb7795c734 Mon Sep 17 00:00:00 2001 From: lanyill Date: Wed, 7 Sep 2022 10:22:26 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0matrix2d=E5=AF=B9=E8=B1=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: lanyill --- api/@internal/component/ets/canvas.d.ts | 6 +-- api/common/full/canvaspattern.d.ts | 54 +------------------------ 2 files changed, 4 insertions(+), 56 deletions(-) diff --git a/api/@internal/component/ets/canvas.d.ts b/api/@internal/component/ets/canvas.d.ts index 6c1072d53d..824ca5a807 100644 --- a/api/@internal/component/ets/canvas.d.ts +++ b/api/@internal/component/ets/canvas.d.ts @@ -223,7 +223,7 @@ declare class Path2D extends CanvasPath { * Adds a path according to the specified path variable. * @param path Indicates the path object to be added. * @param transform Transformation matrix of the new trail - * @since 8 + * @since 9 */ addPath(path: Path2D, transform?: Matrix2D): void; @@ -910,7 +910,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Obtains the currently applied transformation matrix. - * @since 8 + * @since 9 */ getTransform(): Matrix2D; @@ -953,7 +953,7 @@ declare class CanvasRenderer extends CanvasPath { * The 2D transformation effect is added. The current transformation matrix is not overwritten and * the transformations are superimposed for multiple times. * @param transform 2D transformation matrix. For details, see {@link Matrix2D}. - * @since 8 + * @since 9 */ setTransform(transform?: Matrix2D): void; diff --git a/api/common/full/canvaspattern.d.ts b/api/common/full/canvaspattern.d.ts index 8e855021a0..4c75247428 100644 --- a/api/common/full/canvaspattern.d.ts +++ b/api/common/full/canvaspattern.d.ts @@ -23,7 +23,7 @@ export interface CanvasPattern { * Adds the matrix transformation effect to the current template. * @syscap SystemCapability.ArkUI.ArkUI.Full * @param transform transformation matrix - * @since 8 + * @since 9 */ setTransform(transform?: Matrix2D): void; } @@ -76,58 +76,6 @@ export class Matrix2D { */ translateY?: number; - /** - * Transforms the current 2D matrix back to the identity matrix (i.e., without any rotational - * translation scaling effect) - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - identity(): Matrix2D; - - /** - * Transform the current 2D matrix into an inverse matrix (that is, the transformation effect - * is the opposite effect of the original) - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - invert(): Matrix2D; - - /** - * The matrix is superimposed in right multiplication mode. When the input parameter is empty, - * the matrix is superimposed. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @param other Matrix to be superimposed - * @since 8 - */ - multiply(other?: Matrix2D): Matrix2D; - - /** - * Adds the rotation effect of the X and Y axes to the current matrix. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @param rx Rotation effect of the X axis - * @param ry Rotation effect of the Y-axis - * @since 8 - */ - rotate(rx?: number, ry?: number): Matrix2D; - - /** - * Adds the translation effect of the X and Y axes to the current matrix. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @param tx X-axis translation effect - * @param ty Y-axis translation effect - * @since 8 - */ - translate(tx?: number, ty?: number): Matrix2D; - - /** - * Adds the scaling effect of the X and Y axes to the current matrix. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @param sx X-axis scaling effect - * @param sy Y-axis scaling effect - * @since 8 - */ - scale(sx?: number, sy?: number): Matrix2D; - /** * Constructs a 2D change matrix object. The default value is the unit matrix. * @syscap SystemCapability.ArkUI.ArkUI.Full -- Gitee