JCheckbox and DPI

Java version 1.5.0_06
I have a column in a table that contains check boxes. Using the Windows look and feel the spacing (insets) around the check box in each cell is not proportionally the same for 96 DPI as it is for 120 DPI.
Using the default look and feel the check boxes are proportionally the same.
Is there a way to keep the proportions the same regardless of the DPI setting?
Thanks for you help

Merging 2 cells or mergin 2 different columns into 1 column?
if u need to merge 2 cells for different rows here is the link
http://codeguru.earthweb.com/java/Swing/JTable/index.shtml
If you r trying to make 2 column values in one column create custom cell renderer and editor, which will be a JPanel having JTextField and Combo box.
There is an article in the given link which shows how to set any swing component as a cell renderer (and i guess as a cell editor).

Similar Messages

  • I would appreciate it if someone could advise me as to the optimum resolution, dimensions and dpi for actual photographic slides that I am scanning for use in a Keynote Presentation, that will be projected in a large auditorium.  I realize that most proje

    I would appreciate it if someone could advise me as to the optimum resolution, dimensions and dpi for actual photographic slides that I am scanning for use in a Keynote Presentation, that will be projected in a large auditorium. I realize that most projectors in auditoriums that I will be using have 1024 x 1200 pixels, and possibly 1600 x 1200. There is no reference to this issue in the Keynote Tutorial supplied by Apple, and I have never found a definitive answer to this issue online (although there may be one).
                Here’s my question: When scanning my photographic slides, what setting, from 72 dpi to 300 dpi, would result in the best image quality and use up the most efficient amount of space? 
                Here’s what two different photo slide scanning service suppliers have told me: 
    Supplier No. 1 tells me that they can scan slides to a size of 1544 x 1024 pixels, at 72 dpi, which will be 763 KB, and they refer to this as low resolution (a JPEG). However, I noticed when I looked at these scanned slides, the size of the slides varied, with a maximum of 1.8 MB. This supplier says that the dpi doesn’t matter when it comes to the quality of the final digital image, that it is the dimensions that matter.  They say that if they scanned a slide to a higher resolution (2048 x 3072), they would still scan it at 72 dpi.
    Supplier No. 2: They tell me that in order to have a high quality image made from a photographic slide (starting with a 35 mm slide, in all cases), I need to have a “1280 pixel dimension slide, a JPEG, at 300 dpi, that is 8 MB per image.” However, this supplier also offers, on its list of services, a “Standard Resolution JPEG (4MB file/image – 3088 x 2048), as well as a “High Resolution JPEG (8 MB file/image – 3088x2048).
    I will be presenting my Keynotes with my MacBook Pro, and will not have a chance to try out the presentations in advance, since the lecture location is far from my home, so that is not an option. 
    I do not want to use up more memory than necessary on my laptop.  I also want to have the best quality image. 
    One more question: When scanning images myself, on my own scanner, for my Keynote presentations, would I be better off scanning them as JPEGs or TIFFs? I have been told that a TIFF is better because it is less compressed. 
    Any enlightenment on this subject would be appreciated.
    Thank you.

    When it comes to Keynote, I try and start with a presentation that's 1680 x 1050 preset or something in that range.  Most projectors that you'll get at a conference won't project much higher than that and if they run at a lower resolution, it's better to have the device downsize your Keynote.  Anything is better than having the projector try and upsize your presentation... you work hard to make it look good, and it's mangled by some tired Epson projector.
    As far as slides go, scan them in at 150 dpi or better, and make them at least the dimensions of your presentation.  Keynote is really only wanting 72dpi, but I do them at 150, just in case I need to print out the presentation as a handout later, and having the pix at 150 dpi gives me a little help with their quality on a printer.
    You'd probably have to drop in the 150 versions again if you output the Keynote to .pdf or Word or something, but at least you have the option.
    And Gary's right (above) go ahead and scan them as TIFFs.  Sooner or later you'll want to do something else with these slides (like make something for an iPad or the like) and having them as TIFFs keeps your presentation looking good.
    Finally, and this is a big one, get to the location for your presentation ahead of time if you can, and plug the laptop in and see what you get.  There's always connection problems. Don't let the AV bonehead tell you everything will work just fine ('... I don't have any adapters for a Mac...') .  See it for yourself... you're the one that's standing up there.  Unless it's your boss, then you better be really sure it works.

  • Image size and dpi for iDVD menu custom background?

    I created a custom background for my iDVD menu. When showing
    on my TV, part of the words and image is cut off on each side, even after adjusting my tv picture between wide screen and standard screen.
    What is the correct size and dpi to make a photograph to use as a background
    image in the menus? This may have been answered before, so I apologize for posting the same question, if so.

    iDVD will try to downsize the image to work, but your TV often will overscan with the result being edges clipped off. The amount of clipping can vary, so the "TV Safe" settings will typically be the center 80-90% of the image. So, if you add a border that makes the image 10-15% larger, that should display the whole image. For example, if you had a 150 dpi image that was 640x480, you could put a 10% border on it so the final image was 704x528.
    John

  • Is there a way to minimize packaged links sizes to that of resized dimensions and dpi  InDesign C

    Looking for a way to minimize packaged links sizes to that of resized dimensions and dpi?
    Is this a script? How would I go about finding something like this? What is the best way to
    not duplicate images. Storage is beginning to become a problem!
    Thanks,
    Alex

    Hey Alex,
    I think that a plugin called Link Optimizer is just what you're looking for.
    http://zevrix.com/linkoptimizer.php
    Cheers,
    -Andrew

  • What is theoptimal file size for stills, and dpi?

    what is theoptimal file size for stills, and dpi?

    In video dpi is not relevent. What counts in video is pixels. In FCP most recommendations I have seen is to size your stills so they have no more than 3 times the pixels in your project aspect ratio. For example if your project is 1280x720 then stills should be no more than 3 times the 1280x720. This allows you to crop the stills and still have good resolution. If no cropping is anticipated then they could be the same size as your project.

  • Jpeg and dpi?

    How do I create in jpeg format an image no larger than 8" h x 8" w at a resolution of 300dpi or less that I can transfer to a CD-Rom that is PC compatible?  I'm entering a sculpture competion, and these are the requirements.  Many thanks!

    If you don't have Photoshop or something like it. Double click the image and it should load in "Preview" from there you can go to the "tools" menu and select "Adjust Size" option. Default is to show size in pixels but you can change it to inches.
    This allows you to edit the size and DPI. But if your image is not already large enough it's going to get grainy when you change it. Also 8*8 is a square so if you don't want to distort it you need to size it so the smallest side is 8" and then after that use crop to make the other side 8".
    You can then save it as jpg and burn it to a CD, it will be readable on a PC.

  • Air 15 known issues - wrong screen size and dpi

    Will the next update of Air 15 solve the issues below..
    the dpi problem with iPhone 6 plus is a show stopper,  i cant get away with delivering a reduced dpi
    ... under pressure to update 20+ applications  ...
    Known Issues AIR  15.0.0.183
    [ iPhone 6 Plus] [Launch image] A blank screen observed in apps when Default-568h@2x is packaged.
    [ iPhone 6 Plus] Wrong screen size and dpi is returned through the runtime APIs .
    [ iPad 3 and later] iPhone Launch image(Default@2x. png ) appears on iPad if iPhone launch images are packaged along with iPad launch images
    Well done to the Air team for the good work done so far, not easy keeping up with Apple on IOS8  at the moment...

    I am having simliar issue where I can get the iphone 6 launch image to work but not the iphone 6+ when using [email protected], 2208x1242.  Also the stage.fullScreenWidth/Height give 1472x828, which is 2/3 the expected dimensions or 736x414 at scale factor 2, not 3.  I hope adobe fixes this soon or we won't be able to launch new games with Apple as it is a requirement to have your apps Iphone 6/6+ optimized.  If this isn't fixed soon were pretty much forced to abandon adobe and move onto another software solution that will allow us to build for Apple.

  • Regarding JCheckBox and JRadioButton

    hi,
    I have a screen which contains JCheckBox and JRadioButton component on it. when focus is on checkbox i wanted the background color to be green. But once the focus is lost, the background color should be changed to normal.
    Is it possible? Please help me out.. I need it very urgently.
    regards,
    Deepa Raghuraman

    Hello!
    If you mean keyboard focus:
    yourCheckBox.addFocusListener(new FocusListener() {
            public void focusGained(FocusEvent e) {
                 // change color to green
            public void focusLost(FocusEvent e) {
                 // change color to 'normal'
    });I hope it helps you.
    regards
    Feri

  • Cropping in PS while Maintaining Aspect Ratio and DPI

    I shoot the Nikon D3, RAW (.NEF) and convert through ACR. Through ACR, the DPI is set to 300 DPI; the DPI caries over to Photoshop.
    I crop in Photoshop using the crop tool (not marquee). To maintain 2:3 or 3:2 aspect ratios, the crop tool requires the width and height in inches or pixels. If specifying resolution, the document size will crop to that DPI, if not; the DPI is derived from pixel dimensions.
    In my case, I’ve been cropping at 2in by 3in (or reverse for orientation). The resulting “real” image pixel dimensions are still very high (correct to crop size) but the document size reported in PS is 2in by 3in with a wildly high DPI. By changing the resolution back to 300 DPI through Photoshop, the document size returns to normal. Therefore the picture has not lost anything; it appears to only be a function of the Meta data. The pixel dimensions remain constant while the document size and DPI change.
    It apears that you canot specify an aspect ratio via the crop tool without defining it in inches or cm. You can do it with the marquee tool but the marquee tool sucks for cropping. You can however crop in ACR with the crop tool by merely specifying the aspect ratio (not in inches or cm). In summary, the PS crop tool is based in inches or cm while the ACR crop tool is simply aspect ratio.
    What I can do to crop in PS while maintaining aspect ratio and defined DPI. Is there a work-around, magic trick, or something else I can do to fool the PS crop tool into an aspect ratio not based in inches or cm?

    Just to summarize:
    Setting a dimensioned ratio (e.g., 2 in by 3 in for Width and Height) in the Crop tool without filling in a Resolution value yields a crop with the desired aspect ratio, and without any resampling.
    There is no way to specify a ratio with the crop tool, specifically, as the OP has requested, though in a future version perhaps specifying simple numbers there without any units might be a way Adobe could facilitate this.  It would be a nice addition and with little downside.
    I guess what I don't understand, though, is why the OP cares about the "high" resulting dpi value?  It's just a number.
    Expanding on this, the Resolution is nothing but a metadata value that can be changed at will (e.g., through Image - Image Size... - uncheck Resample) at any time in the future.  There is ALWAYS a Resolution value associated with the image, both before and after the crop (though the crop tool may end up changing it; so what?).  In short, the Resolution is just an arbitrary figure until such time as the user wants to use the image for a purpose (e.g. printing).
    Always think in terms of pixel dimensions (number of pixels horizontally and vertically) while editing, then think about dpi right before publishing.  It's hard to go wrong this way.
    -Noel

  • How to change print size and DPI setting in Aperture

    If I import a raw image from my camera (D2X) to Aperture and print the image at about 8"x10" through Aperture, it prints at about 300 DPI, if I change to size of the same image to 12"x18", in Aperture, it prints the image at about 166 DPI. I do not believe there is a way to change this in Aperture.
    My question is, can I open the image at 8"x10" in PS, change the size and resolution to 12"x18" and 300 DPI then save it, open it again in Aperture and print it. If I do these things, will the image printed in Aperture still be 300 DPI and how can I check it to see if that is the case?
    I have not been able to find the DPI setting anywhere in Aperture to confirm that it is what I want or need.

    "You can make the pixels bigger by making the image larger but you can't add any more pixels without running some kind of interpolation filtration like GenuineFractals or a recomputation like bicubic."
    Thank you for your explanation and that brings me exactly to the point of my question.
    Can I interpolate my original NEF raw image after conversion by Aperture to a much larger image for print using something similar to what Photoshop does with it's bicubic smoother or as is done in genuine fractals or must I go out of Aperture and back if I want to print with Aperture. I am hoping you will tell me that Aperture is or will be capable of interpolating an image to a larger one with more than just the pixels supplied by the camera. I do not belive that these are not enough by themselves to print a quality image in a much larger size.
    I may be wrong, but I believe that it is somewhat common practice to interpolate an image to get a greater resolution printed image at a size larger that what is possible with a resolution provided by the (D2x in my case) DSLR camera.
    Or is this just a tempest in a teapot. In other words, will I be able to take the image out of the D2x (12.5 megapixels) and print a 13x 19" image with the same quality in Aperture (uninterpolated but enlarged) as an interpolated image in PS or Genuine Fractals and then in PS?
    Thank you

  • Help with page size and dpi

    hello, i am about to render an autocad drawing in Photoshop, i need to print this out on a piece of paper that is 36 x 48, pretty large
    should the image be 300 dpi to not be pixelated when i print it out?
    also, i am doing this on a laptop, the file size be huge, right? worried about it crashing a lot , thanks for any advice i am pretty new to photoshop

    rupertsandy wrote:
    thanks for the help!! here is some more info
    these will be hanging on a wall closet  reviewers will be probably be couple feet away
    i am going to have them printed at a professional print place who do lots of Architecture plans, so  I am assuming they have the ability and machines to
    print it the way i would need it printed, if I need to ask them about this, what questions should i ask?
    ah good! then the answer is, ask the printer!   (always ask the printer when using a pro service, that's part of what you're paying them for!) they should be able to tell you precisely how to set up your file for best output on their machines.
    good luck, dave

  • Having trouble with JCheckBox and JTree

    I am trying to render the JTree to display JCheckBox's instead of just ordinary JLabels.
    It's fine, compiles, and when you view it it looks normal, until you try to check one.
    You can't check it at all.
    What am i doing wrong with this?
    Thanks

    OK, here it is...
    public class EmotiTreeCellRenderer extends DefaultTreeCellRenderer {
         protected JCheckBox label;
         public Component getTreeCellRendererComponent(JTree tree, Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean hasFocus) {
              if ( value instanceof DefaultMutableTreeNode ) {
                   label = new JCheckBox();
                   label.setOpaque( false );
                   if ( selected && hasFocus ) {
                        label.setForeground( Color.blue );
                   DefaultMutableTreeNode node = (DefaultMutableTreeNode)value;
                   Object userObject = node.getUserObject();
                   if ( userObject instanceof Emoticon ) {
                        Emoticon emoticon = (Emoticon)userObject;
                        String icon = emoticon.getIconKeys();
                        try {
                             label.setText( "<html><body><img src=\"" + new File( emoticon.getRealPathToEmoticon() ).toURL().toString() + "\" alt=\"" + parseAlt( icon ) + "\"> " + parseAlt( icon ) + "</body></html>" );
                        } catch ( MalformedURLException mfe ) {
                             label.setText( "<html><body>" + parseAlt( icon ) + "</body></html>" );
                        return label;
                   } else if ( userObject instanceof EmotiPack ) {
                        EmotiPack pack = (EmotiPack)userObject;
                        label.setText( pack.getName() );
                        return label;
              return super.getTreeCellRendererComponent( tree, value, selected, expanded, leaf, row, hasFocus );
         protected String parseAlt(String html) {
              return html.replace( "<", "<" ).replace( ">", ">" ).replace( "\"", "&#34;" );
    }

  • Layout and DPI

    Hello,
    I know how to change text padding for different dpi with @media tag in css file.
    I konw how to choose image with MultiDPIBitmapSource
    Layout properties like gap, padding... are not styles, not bitmapSource
    How can I simply choose layout visual properties like gap and padding based on DPI ?

    Those values should be applied in a skin. Use the dpi selector in CSS to choose an appropriate skin for the DPI, or create a skin that implements various custom styles to determine the layout values.

  • Learning SQL Query with JCheckBox and JButton

    Hello,
    I am learning how to access a very simple Access table. I am able to connect to the database and return a simple query. As I make it more complicated is where I have confused myself. The program is suppose to allow the user to pick any field they want to query using JCheckBox. After they have checked the fields off, the run query button is hit and outputs the results in a JOPtion Pane with a JTable. I am trying to do a test run and I can't make the query at least output something. If I can get any clues to the right direction would be appreciated. Thanks.
    package mypackage25;
    import java.sql.*;
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class QueryAddressBook extends JFrame
        private JLabel selectQueryLabel;
        private JCheckBox firstName, lastName,
                       telephone, addressI, addressII, city,
                       state, zip;
        private JPanel selectQueryPanel, checkBoxPanel, executePanel;
        private JButton runQueryButton, clearSQLButton;
        private Connection connection;
        private Statement statement;
        private ResultSet resultSet;
        public QueryAddressBook()
          super("Query an Address Book");
          //Driver and Connection
          try
          //Driver for MicrosoftAccess
          Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
          //Inform the user that the Driver was loaded successfully
          System.out.println("Driver Loaded");
          //Connect to specific database(i.e. MyAddress3) in Access
          Connection connection=DriverManager.getConnection("jdbc:odbc:MyAddress3");
          //Inform User
          System.out.println("Database connected");
          }//end try
          catch(ClassNotFoundException cnfe)
            cnfe.printStackTrace();
          }//end catch
          catch(SQLException sqle)
            sqle.printStackTrace();
          }//end catch
          //get content pane and set its layout
          Container container=getContentPane();
          container.setLayout(new BorderLayout());
          //GUI Components
          selectQueryLabel=new JLabel("Select Fields to be Queried");
          firstName=new JCheckBox("First Name");
          lastName=new JCheckBox("Last Name");
          telephone=new JCheckBox("Telephone");
          addressI=new JCheckBox("Address I");
          addressII=new JCheckBox("Address II");
          city=new JCheckBox("City");
          state=new JCheckBox("State");
          zip=new JCheckBox("Zipcode");
          //register listeners for JCheckBoxes
          CheckBoxHandler handler=new CheckBoxHandler();
          firstName.addItemListener(handler);
          lastName.addItemListener(handler);
          telephone.addItemListener(handler);
          addressI.addItemListener(handler);
          addressII.addItemListener(handler);
          city.addItemListener(handler);
          state.addItemListener(handler);
          zip.addItemListener(handler);
          //set up selectQueryPanel
          selectQueryPanel=new JPanel();
          selectQueryPanel.setLayout(new FlowLayout());
          selectQueryPanel.add(selectQueryLabel);
          //set up CheckBox Panel
          checkBoxPanel=new JPanel();
          checkBoxPanel.setLayout(new FlowLayout());
          checkBoxPanel.add(firstName);
          checkBoxPanel.add(lastName);
          checkBoxPanel.add(telephone);
          checkBoxPanel.add(addressI);
          checkBoxPanel.add(addressII);
          checkBoxPanel.add(city);
          checkBoxPanel.add(state);
          checkBoxPanel.add(zip);
          //set up execute panel
          executePanel=new JPanel();
          executePanel.setLayout(new FlowLayout());
          //set up buttons
          runQueryButton=new JButton("Run Query");
          clearSQLButton=new JButton("Clear SQL");
          runQueryButton.addActionListener
            new ActionListener()
              public void actionPerformed(ActionEvent event)
                if(event.getSource().equals(runQueryButton))
                  runSQLQuery();
          executePanel.add(runQueryButton);
          executePanel.add(clearSQLButton);
          container.add(selectQueryPanel, BorderLayout.NORTH);
          container.add(checkBoxPanel, BorderLayout.CENTER);
          container.add(executePanel, BorderLayout.SOUTH);
          setSize(800,150);
          setVisible(true);
        public static void main(String args[])
          QueryAddressBook dwgui=new QueryAddressBook();
          dwgui.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        }//end main
        //private inner class for ItemListener event handling
        private class CheckBoxHandler implements ItemListener
          public void itemStateChanged(ItemEvent event)
          }//end method itemStateChanged
        }//end private inner class CheckBoxHandler
        private void runSQLQuery()
          String output="";
          try
            statement=connection.createStatement();
            resultSet=statement.executeQuery("select firstName from address");
            while(resultSet.next())
              output+=resultSet.getString(1)+"\n";
            JOptionPane.showMessageDialog(null,output);
            System.out.println(output);
          }//end try
          catch(SQLException sqle)
            sqle.printStackTrace();
          }//end catch
        }//end runSQLQuery
    }//end class

    At present your query string is
    "Select firstName from Address"
    Instead of using the above hardcoded string, try to build the
    query String using logic that checks which check boxes are selected
    by the user.
    Example..
    String query = "SELECT ";
    if (firstName.isSelected()) {
    query = query + " firstName";
    Be sure, you add the comma properly between two fields :-)

  • CFImage Functions and DPI / Image Quality.

    I am doing some work that involves taking images supplied from a product called Fotoweb and putting them into PDF files using cfdocument.
    We are noticing a degradation in image quality that seems to be coldfusion related.
    In the code below I am reading in an image @ 300DPI from the Fotoweb product. It is definately 300dpi. I am then writing the image back to a file without any manipulation and it becomes 96DPI.
    <!--- Read In The Image --->
    <cfset theImage=ImageRead(aUrlToGetImageFrom)>
    <!--- Write Out the Image --->
    <cfset ImageWrite(theImage,aFileToWriteTo,"1.0")>
    In production we want to be able to resize the image to 5"x7" at 300DPI in a pdf. However as soon as coldfusion gets involved we get bumped down to 96dpi.The image quality is very important as these pdfs will ultimately be printed.
    Is there anyway of telling CF to keep the image at 300dpi.
    Thanks in advance
    Nick

    You comparison method is seriously flawed. For 1 image to be at 72 DPI (a software supplied setting) & the other to be at 180 DPI it means that one image has been enlarged (180 divided by 72) 2.5 times more than the other to view it on screen. Zoom in on the good image until it's 2.5 times larger & see how it looks.
    Next thing you need to know is that camera technique becomes more important as pixel count increases. an 18 Mpixel image will have an 80% increase in softness over the 10 Mpixel camera from identical camera shake. To make any accurate form of comparison you will need to eleminate the possibility of introducing camera shake into the test. You will also need very similar lighting & the subject must also be stationary for all test shots. (IE that eye (or the person it's attached to) may have moved during one shot but not the othern
    "A skill is developed through constant practice with a passion to improve, not bought."

Maybe you are looking for

  • Ipod not being detected on my dell latitude620

    I just got a dell latitude 620 laptop My ipod is being detected as a "device" My ipod will charge, but itunes does not recognize it. I've uninstalled itunes and reinstalled it twice. And tried about 90% of what apple support suggests There is nothing

  • DreamColor Monitor from PC via VGA: Color-Space & Settings?

    Context: Premiere CC on a WIndows 7 laptop with an external DreamColor monitor connected via VGA port (for convenience rather than bit depth). What color space is appropriate in the DreamColor settings, i.e. what is the VGA likely to be supplying?  

  • Multiple instances of jrun.exe running?

    Is it common for there to be more than one instance of jrun.exe running in a non-clustered installation of CF7? There have been episodes where jrun.exe seems to get taxed on moderately size queries. After looking at Task Manager on Win2K3 server - th

  • System id using java

    how to get system id using java ,also MAC address?

  • Screen layout changes-MIGO

    We want to make some changes in screen layout for goods receipt for purchase order as well as outbound delivery using MIGO transaction. we want to keep material code just beside the material description. Plz suggest the process flow and transaction c