Hi,
I was wondering is there any way to draw a line with an arrow, which can indicate the from ‘point 1’ point to ‘point 2’.
Does anyone know how to implement this?
Thanks
Shannon
Hi,
I was wondering is there any way to draw a line with an arrow, which can indicate the from ‘point 1’ point to ‘point 2’.
Does anyone know how to implement this?
Thanks
Shannon
Hi,
I haven't used any of these myself, but OGL and FloatCanvas come to
mind in this context; see the wxpython demo:
More windows/controls: FloatCanvas
Miscelaneous: OGL
There are likely some other graphic libraris, with this capabilitry.
hth,
vbr
2013/2/21 Shannon <shannonzheng5@gmail.com>:
Hi,
I was wondering is there any way to draw a line with an arrow, which can
indicate the from 'point 1' point to 'point 2'.
Does anyone know how to implement this?Thanks
Shannon--
You received this message because you are subscribed to the Google Groups
"wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to wxpython-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Probably overkill, but VPython (vpython.org), which is now based on wxPython, makes it extremely easy to draw a 3D arrow. The single statement
arrow()
draws a default white arrow with its tail at the origin, pointing to the right, with length 1. You can optionally specify a tail position, a direction and length, and a color:
A = arrow(pos=(1,2,-1), axis(5,2,3), color=color.cyan)
Later in the program you can alter any of these attributes. For example,
A.color = color.red
With the mouse you can zoom and rotate the “camera” that is viewing the 3D scene.
Indeed -- for FloatCanvas, look at the main Demo, look at the "Arrows"
demo under the "Tests" Menu - the arrows are not particularly pretty,
but you could make your own DrawObject with prettier ones if you want.
There are also bunch more little FloatCanvas demos in SVN also:
http://svn.wxwidgets.org/svn/wx/wxPython/3rdParty/FloatCanvas/Demos/
The VectPlot.py demo uses arrows.
-Chris
On Thu, Feb 21, 2013 at 1:21 PM, Vlastimil Brom <vlastimil.brom@gmail.com> wrote:
2013/2/21 Shannon <shannonzheng5@gmail.com>:
I was wondering is there any way to draw a line with an arrow, which can
indicate the from 'point 1' point to 'point 2'.
I haven't used any of these myself, but OGL and FloatCanvas come to
mind in this context; see the wxpython demo:
More windows/controls: FloatCanvas
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker@noaa.gov