Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (102)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (322)
Collections:
Other Resources:
JDK 11 java.desktop.jmod - Desktop Module
JDK 11 java.desktop.jmod is the JMOD file for JDK 11 Desktop module.
JDK 11 Desktop module compiled class files are stored in \fyicenter\jdk-11.0.1\jmods\java.desktop.jmod.
JDK 11 Desktop module compiled class files are also linked and stored in the \fyicenter\jdk-11.0.1\lib\modules JImage file.
JDK 11 Desktop module source code files are stored in \fyicenter\jdk-11.0.1\lib\src.zip\java.desktop.
You can click and view the content of each source code file in the list below.
✍: FYIcenter
⏎ com/sun/java/swing/plaf/motif/MotifGraphicsUtils.java
/*
* Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
* ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*/
package com.sun.java.swing.plaf.motif;
import java.awt.Color;
import java.awt.FontMetrics;
import java.awt.Graphics;
import javax.swing.JComponent;
import javax.swing.SwingConstants;
import sun.swing.SwingUtilities2;
/*
* @author Jeff Dinkins
* @author Dave Kloba
*/
final class MotifGraphicsUtils {
/*
* Convenience method for drawing a grooved line
*/
static void drawGroove(Graphics g, int x, int y, int w, int h, Color shadow,
Color highlight)
{
Color oldColor = g.getColor(); // Make no net change to g
g.translate(x, y);
g.setColor(shadow);
g.drawRect(0, 0, w-2, h-2);
g.setColor(highlight);
g.drawLine(1, h-3, 1, 1);
g.drawLine(1, 1, w-3, 1);
g.drawLine(0, h-1, w-1, h-1);
g.drawLine(w-1, h-1, w-1, 0);
g.translate(-x, -y);
g.setColor(oldColor);
}
static void drawStringInRect(JComponent c, Graphics g, String aString,
int x, int y, int width, int height,
int justification) {
FontMetrics fontMetrics;
int drawWidth, startX, startY, delta;
if (g.getFont() == null) {
// throw new InconsistencyException("No font set");
return;
}
fontMetrics = SwingUtilities2.getFontMetrics(c, g);
if (fontMetrics == null) {
// throw new InconsistencyException("No metrics for Font " + font());
return;
}
if (justification == SwingConstants.CENTER) {
drawWidth = SwingUtilities2.stringWidth(c, fontMetrics, aString);
if (drawWidth > width) {
drawWidth = width;
}
startX = x + (width - drawWidth) / 2;
} else if (justification == SwingConstants.RIGHT) {
drawWidth = SwingUtilities2.stringWidth(c, fontMetrics, aString);
if (drawWidth > width) {
drawWidth = width;
}
startX = x + width - drawWidth;
} else {
startX = x;
}
delta = (height - fontMetrics.getAscent() - fontMetrics.getDescent()) / 2;
if (delta < 0) {
delta = 0;
}
startY = y + height - delta - fontMetrics.getDescent();
SwingUtilities2.drawString(c, g, aString, startX, startY);
}
}
⏎ com/sun/java/swing/plaf/motif/MotifGraphicsUtils.java
Or download all of them as a single archive file:
File name: java.desktop-11.0.1-src.zip File size: 7974380 bytes Release date: 2018-11-04 Download
⇒ JDK 11 java.instrument.jmod - Instrument Module
2022-08-06, ≈450🔥, 5💬
Popular Posts:
JDK 11 jrt-fs.jar is the JAR file for JDK 11 JRT-FS (Java RunTime - File System) defined in the "jdk...
This package is the backport of java.util.concurrent API, introduced in Java 5.0 and further refined...
What Is js.jar in Rhino JavaScript 1.7R5? js.jar in Rhino JavaScript 1.7R5 is the JAR file for Rhino...
JDK 11 java.desktop.jmod is the JMOD file for JDK 11 Desktop module. JDK 11 Desktop module compiled ...
maven-core-3.8.6.jar is the JAR file for Apache Maven 3.8.6 Core module. Apache Maven is a software ...