Drawing ellipses on an angle - Xwindows

This is a discussion on Drawing ellipses on an angle - Xwindows ; Hi, I was wondering if anyone could provide with any tips on how to draw ellipses on an angle (ie, other than the default vertical/horizontal orientation) in X-Windows. The function I am trying to use is XDrawEllipse. I am using ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Drawing ellipses on an angle

  1. Drawing ellipses on an angle

    Hi,

    I was wondering if anyone could provide with any tips on how to draw
    ellipses on an angle (ie, other than the default vertical/horizontal
    orientation) in X-Windows.

    The function I am trying to use is XDrawEllipse. I am using "XForms"
    to build my application, however, the provided function "fl_ovall"
    doesn't seem to behave very differently to the X primitive.

    Is it possible to do this? Maybe there is a way to rotate the X and Y
    axes? Clutching at straws here...

    Thankyou


  2. Re: Drawing ellipses on an angle

    On 2007-05-26, captain_oldfield wrote:
    > Hi,
    >
    > I was wondering if anyone could provide with any tips on how to draw
    > ellipses on an angle (ie, other than the default vertical/horizontal
    > orientation) in X-Windows.
    >
    > The function I am trying to use is XDrawEllipse. I am using "XForms"
    > to build my application, however, the provided function "fl_ovall"
    > doesn't seem to behave very differently to the X primitive.
    >
    > Is it possible to do this? Maybe there is a way to rotate the X and Y
    > axes? Clutching at straws here...


    As far as I remember, the answer is no. You'll have to do the math
    yourself and create N line-segments and use XDrawSegments(). If this is
    the only thing you need you are fine. Otherwise it might be wise to have
    a look at libcairo, which provides portable state of the art drawing.

    --- Jan

+ Reply to Thread