|
-
Painting from a Graphics object?
I'm having trouble getting my head around Graphics objects and the paint method. Here's my predicament:
I have a class called DrawSurface which extends JPanel. The only thing that I changed was the paint method which I will use to draw on the DrawSurface. I have a bunch of coordinates that I want to draw onto the DrawSurface. It's not all going to fit on the screen, so I want to use a scrollbar to pan along the drawing. Is there a way that I can draw the entire drawing onto an offscreen Graphics object and then display a portion of that Graphics object on the DrawSurface depending on where the scrollbar is? I know that it's possible to draw a portion of an Image object onto a Graphics object, but what about Graphics to Graphics. Or is there an easier way that I'm overlooking?
Similar Threads
-
Replies: 2
Last Post: 01-10-2006, 11:34 AM
-
By Michael Culley in forum .NET
Replies: 5
Last Post: 05-06-2002, 02:25 AM
-
By Michael Culley in forum .NET
Replies: 1
Last Post: 05-05-2002, 12:02 PM
-
By Jaco de Villiers in forum XML
Replies: 1
Last Post: 06-01-2001, 05:50 PM
-
By Tom Shreve in forum Enterprise
Replies: 0
Last Post: 04-07-2000, 08:15 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks