8340354: Open source AWT desktop properties and print related tests#21197
8340354: Open source AWT desktop properties and print related tests#21197kumarabhi006 wants to merge 3 commits intoopenjdk:masterfrom
Conversation
|
👋 Welcome back abhiscxk! A progress list of the required criteria for merging this PR into |
|
@kumarabhi006 This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 96 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
|
@kumarabhi006 The following label will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command. |
Webrevs
|
| MenuItem itemBackground = | ||
| new MenuItem("Print to Printer in Background"); | ||
| itemBackground.setActionCommand("none"); | ||
| MenuItem itemScreen = new MenuItem("Print to Screen..."); |
There was a problem hiding this comment.
| MenuItem itemScreen = new MenuItem("Print to Screen..."); | |
| MenuItem itemScreen = new MenuItem("Print to Screen..."); |
|
|
||
| PrintJob pj = getToolkit().getPrintJob( | ||
| MainFrame.this, "Print test!", jobAttributes, pageAttributes); | ||
| if( pj == null ) return; |
There was a problem hiding this comment.
| if( pj == null ) return; | |
| if (pj == null) return; |
|
|
||
| class ActionPrintToScreen implements ActionListener { | ||
| public void actionPerformed(ActionEvent ev) { | ||
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); |
There was a problem hiding this comment.
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); | |
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); |
| int width = 100; | ||
| int height = 30; |
There was a problem hiding this comment.
| int width = 100; | |
| int height = 30; | |
| int width = 100; | |
| int height = 30; |
|
|
||
| public Dimension getPreferredSize() | ||
| { | ||
| return new Dimension(width,height); |
There was a problem hiding this comment.
| return new Dimension(width,height); | |
| return new Dimension(width, height); |
|
|
||
| public Dimension getPreferredSize() | ||
| { | ||
| return new Dimension(width,height); |
There was a problem hiding this comment.
| return new Dimension(width,height); | |
| return new Dimension(width, height); |
| // now make things really interesting with a lightweight | ||
| // component at the top of the z-order, that should print | ||
| // _below_ the native guys to match the screen... | ||
| add(new LWButton("LWButton"),0); |
There was a problem hiding this comment.
| add(new LWButton("LWButton"),0); | |
| add(new LWButton("LWButton"), 0); |
| menu3.setFont(new Font("Monospaced", Font.ITALIC, 18)); | ||
| menu3.setEnabled(false); | ||
| menu4.setEnabled(false); | ||
| MenuItem itemPrinter = new MenuItem("Print to Printer..."); |
There was a problem hiding this comment.
| MenuItem itemPrinter = new MenuItem("Print to Printer..."); | |
| MenuItem itemPrinter = new MenuItem("Print to Printer..."); |
| menu3.setEnabled(false); | ||
| menu4.setEnabled(false); | ||
| MenuItem itemPrinter = new MenuItem("Print to Printer..."); | ||
| MenuItem itemScreen = new MenuItem("Print to Screen..."); |
There was a problem hiding this comment.
| MenuItem itemScreen = new MenuItem("Print to Screen..."); | |
| MenuItem itemScreen = new MenuItem("Print to Screen..."); |
| static void printProps(Properties props) | ||
| { | ||
| Enumeration propNames = props.propertyNames(); | ||
| while(propNames.hasMoreElements()) { |
There was a problem hiding this comment.
| while(propNames.hasMoreElements()) { | |
| while (propNames.hasMoreElements()) { |
| printProps(props); | ||
| PrintJob pj = getToolkit().getPrintJob( | ||
| MainFrame.this, "Print test!", props); | ||
| if( pj == null ) { |
There was a problem hiding this comment.
| if( pj == null ) { | |
| if (pj == null) { |
|
|
||
| class ActionPrintToScreen implements ActionListener { | ||
| public void actionPerformed(ActionEvent ev) { | ||
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); |
There was a problem hiding this comment.
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); | |
| PrintFrame printFrame = new PrintFrame( MainFrame.this ); |
| int width = 100; | ||
| int height = 30; |
There was a problem hiding this comment.
| int width = 100; | |
| int height = 30; | |
| int width = 100; | |
| int height = 30; |
|
|
||
| public Dimension getPreferredSize() | ||
| { | ||
| return new Dimension(width,height); |
There was a problem hiding this comment.
| return new Dimension(width,height); | |
| return new Dimension(width, height); |
|
|
||
| public Dimension getPreferredSize() | ||
| { | ||
| return new Dimension(width,height); |
There was a problem hiding this comment.
| return new Dimension(width,height); | |
| return new Dimension(width, height); |
| // now make things really interesting with a lightweight | ||
| // component at the top of the z-order, that should print | ||
| // _below_ the native guys to match the screen... | ||
| add(new LWButton("LWButton"),0); |
There was a problem hiding this comment.
| add(new LWButton("LWButton"),0); | |
| add(new LWButton("LWButton"), 0); |
| */ | ||
|
|
||
| import java.awt.Color; | ||
| import java.awt.Frame; |
There was a problem hiding this comment.
seem to have some extra spaces here
|
/integrate |
|
Going to push as commit 988f13a.
Your commit was automatically rebased without conflicts. |
|
@kumarabhi006 Pushed as commit 988f13a. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
AWT Desktop properties and printer related tests are converted from applet to manual and moved to open.
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/21197/head:pull/21197$ git checkout pull/21197Update a local copy of the PR:
$ git checkout pull/21197$ git pull https://git.openjdk.org/jdk.git pull/21197/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 21197View PR using the GUI difftool:
$ git pr show -t 21197Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/21197.diff
Webrev
Link to Webrev Comment