• Post Reply Bookmark Topic Watch Topic
  • New Topic

Page format user workspace (like Office programs)

 
Louis Sutter
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I am currently programming a form creator similar to a PDF form creator, however it will be used to access a database. The user will be able to import a scanned paper form and insert input text fields where appropriate. I've attached a picture of my concept mock-up to give you an idea of what I'm going for. Think of pretty much any Office program.

I am having a real difficulty with getting what I want. The surrounding menu bars and buttons were a breeze, but I'm having the real difficulty designing the user workspace (page format). I'd also like to add a pixel ruler in the margins of the workspace and support zoom in/out. I have never done this kind of a GUI, and have been trying several ways to make it work with Swing. Down the line I can see myself also having trouble with programming the action listeners/handlers to record the user's click and drag when placing the desired text boxes.

Am I using the correct library? If not, what would you guys suggest and is there a good tutorial or book for it? If I am on the right track, any suggestions on how to get the desired result?
concept.jpg
[Thumbnail for concept.jpg]
 
Les Morgan
Rancher
Posts: 717
17
C++ Java MySQL Database Netbeans IDE Oracle Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think would start looking at scrollable pane, JScrollPane, with the idea of overriding paintComponent to render your scanned document image onto the background of the container.
That would also give you the ability for you to put your grid and ruler on your image and not have it durable.

I don't understand your concern about the dragging of the items and retrieving their location, this is a fairly simple task done with a listener--drag (not: drag and drop).

<edit addition> You are going to have to go to a graphics type of scenario for your zooming in and out, so all of your concerns can be addressed as I've described.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!