Qt:Документация 4.3.2/q3canvasline

Материал из Wiki.crossplatform.ru

Перейти к: навигация, поиск
40px Внимание: Актуальная версия перевода документации находится здесь

__NOTOC__

Image:qt-logo.png

Главная · Все классы · Основные классы · Классы по группам · Модули · Функции

Image:trolltech-logo.png

Содержание

[править] Q3CanvasLine Class Reference
[ Qt3Support module]

The Q3CanvasLine class provides a line on a Q3Canvas. Далее...

 #include <Q3CanvasLine>

This class is part of the Qt 3 support library. It is provided to keep old source code working. Мы настоятельно не рекомендуем использовать этот класс в новом коде. See Porting to Qt 4 for more information.

Note to Qt Desktop Light Edition users: This class is only available in the Qt Desktop Edition.

Inherits Q3CanvasPolygonalItem.

[править] Открытые функции

[править] Дополнительные унаследованные члены


[править] Подробное описание

The Q3CanvasLine class provides a line on a Q3Canvas.

The line inherits functionality from Q3CanvasPolygonalItem, for example the setPen() function. The start and end points of the line are set with setPoints().

Like any other canvas item lines can be moved with Q3CanvasItem::move() and Q3CanvasItem::moveBy(), or by setting coordinates with Q3CanvasItem::setX(), Q3CanvasItem::setY() and Q3CanvasItem::setZ().

See also QtCanvas and Porting to Graphics View.


[править] Описание функций-членов

[править]
Q3CanvasLine::Q3CanvasLine ( Q3Canvas * canvas )

Constructs a line from (0,0) to (0,0) on canvas.

See also setPoints().

[править]
Q3CanvasLine::~Q3CanvasLine ()

Destroys the line.

[править]
QPoint Q3CanvasLine::endPoint () const

Returns the end point of the line.

See also setPoints() and startPoint().

[править]
int Q3CanvasLine::rtti () const [virtual]

Returns 7 ( Q3CanvasItem::Rtti_Line).

Reimplemented from Q3CanvasItem.

See also Q3CanvasItem::rtti().

[править]
void Q3CanvasLine::setPoints ( int xa, int ya, int xb, int yb )

Sets the line's start point to (xa, ya) and its end point to (xb, yb).

[править]
QPoint Q3CanvasLine::startPoint () const

Returns the start point of the line.

See also setPoints() and endPoint().



Copyright © 2007 Trolltech Trademarks
Qt 4.3.2