About 51 results
Open links in new tab
  1. java - Java2D: Increase the line width - Stack Overflow

    May 15, 2010 · The methods of the Graphics2D interface that use the outline Shape returned by a Stroke object include draw and any other methods that are implemented in terms of that method, …

  2. Drawing your own Graphic in Java with Graphics2d

    Jun 14, 2022 · Drawing your own Graphic in Java with Graphics2d Asked 3 years, 8 months ago Modified 3 years, 8 months ago Viewed 726 times

  3. awt - Graphics and Graphics 2D in java - Stack Overflow

    Oct 29, 2019 · java awt graphics2d java-2d japplet edited Oct 29, 2019 at 19:58 Andrew Thompson 169k 42 224 441

  4. java - Draw text with graphics object on JFrame - Stack Overflow

    Graphics2D g2d = (Graphics2D)g; g2d.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_ON); } g.drawString("This is gona be awesome", 200, …

  5. Java - Swing - Graphics 2D - Stack Overflow

    May 31, 2013 · Graphics2D Graphics g is-a It's a problem of compatibility with older Java code. Graphics2D, as explained in documentation, is a class that inherits from Graphics and provides …

  6. Convert a Graphics2D to an Image or BufferedImage

    Jul 4, 2011 · To do that, I use the java.awt.Graphics2D. But, how can I do to save the user draw image as a JPEG image, or at least, convert it to a BufferedImage or something?

  7. java - How to draw a String using Graphics2D class? - Stack Overflow

    Jul 6, 2015 · Graphics2D g2d = (Graphics2D) noConnection.getGraphics(); this gives you a pointer to the Graphics object, but not while the window is being drawn. Instead, you should override the …

  8. java - How to create a Graphics2D instance? - Stack Overflow

    May 13, 2013 · What's the easiest way in Java SE 7 to obtain an instance just to plot a few points for debugging? Desktop environment.

  9. java - How do you use re-size all Graphic2D - Stack Overflow

    Dec 12, 2014 · 1 This is actually quite easy in Java. In a Graphics2d environment, the logical coordinate system (the coordinates you use in the drawing routines) and the physical coordinate system (the …

  10. Drawing Transparent Images In Java Graphics2D - Stack Overflow

    Nov 25, 2011 · I want to draw a PARTIALLY transparent image on top of another (Making shadows over things). I am currently using java's Graphics2D class to render, I've been told to set the composite to …