0

Draw a line between components

asked 2009-09-17 15:12:37 +0800

rex gravatar image rex
120 2

How to draw a line between Zk components? Not just a horizontal line but a zig-zag line.
Basically, I have a hyperlink that I need to connect to a small window. And it is not one instance on the same page there could be more than 10 such connectors. Each connector, connects the link to a discussion window.

Any idea is greatly appreciated.

delete flag offensive retag edit

7 Replies

Sort by ยป oldest newest

answered 2009-09-18 18:47:32 +0800

rex gravatar image rex
120 2

Any ideas? Any one?

link publish delete flag offensive edit

answered 2009-09-21 00:52:23 +0800

joylo0122 gravatar image joylo0122
688 1
www.zkoss.org

updated 2009-09-21 00:52:39 +0800

@rex

If you want draw a zig-zag line, you should calculate and draw by yourself, there's not any easy way to draw it now.
And there's a suggestion for your case(show window for different connectors), apply a Composer to control the zul page,
use Executions.createComponent() to decide when and how to show the window. If all the connectors will do things in the
same window, you could use Server-Push or script to auto-refresh the window, make sure all users will see the same data.

Reference:
ZK Composer
ZK-API Executions.createComponent()
Server-Push

/Joy

link publish delete flag offensive edit

answered 2009-09-21 05:08:40 +0800

rex gravatar image rex
120 2

Thanks so much for your reply.
However, the key part for me is how to draw a line in ZK. I can figure out how to calculate the points but how do I connect the two points is the question.

Any pointers in this regard will be greatly appreciated.

link publish delete flag offensive edit

answered 2009-09-21 05:42:49 +0800

baskaraninfo gravatar image baskaraninfo
536 2 2 9

You can draw a line using canvas component.

The following link may help you:
http://www.zkoss.org/smalltalks/canvas/canvas.dsp

link publish delete flag offensive edit

answered 2009-09-22 03:08:03 +0800

jj gravatar image jj
638 3

Have you tried the separator component?

link publish delete flag offensive edit

answered 2009-09-23 15:02:26 +0800

rex gravatar image rex
120 2

Thanks so much for all the info.

Canvas looks promising, I am going to see how it can help me.

I have used the seperator for spacing only, is there something else that it does?

link publish delete flag offensive edit

answered 2009-09-23 15:49:00 +0800

terrytornado gravatar image terrytornado flag of Germany
9393 3 7 16
http://www.oxitec.de/

<separator bar="true" /> shows a line. Additionally you can set the lines orientation to vertical or horizontal.

regards
Stephan

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2009-09-17 15:12:37 +0800

Seen: 1,262 times

Last updated: Sep 23 '09

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More