Asdakamessoy
Asdakamessoy

Reputation: 87

implementing UI for relationship between Entities of a database via Swing-java

Relationship is one to one

I want to implement UI like as image which attach my two tables; im using JAVA swing to implement a drag and drop User interface for users to generate a database xml code e.g. DB Designer Fork.

Have implemented design of tables just wanted to get idea how to make a line which will be attached to the table han onclick.

Upvotes: 1

Views: 606

Answers (1)

trashgod
trashgod

Reputation: 205795

This example uses drawLine() to connect JInternalFrame instances in a JDesktopPane, but you can draw() any desired Shape. PointyThing illustrates a common line decoration.

Also consider an existing library, as suggested here.

Upvotes: 1

Related Questions