Presets for inserting images

Hello all!
Formerly, when I inserted images using the tab Homesite used
width, height and alt attributes. Now, he omits width and height.
Also in the folder list Homesite always starts with
gif-images and I have to select jpg-files first. At home I always
got all image-filetypes. I already tried the tip from the site
http://www.wilk4.com/asp4hs/tips.htm
but it didn't help.
Any ideas what to do?
Thank you in advance,
Silkea

how are you inserting images?
what types of images don't insert width & height?

Similar Messages

  • Less white space for Insert image

    Eliminate some vertical white space on the Insert Image window.
    Sometimes this large window runs off the bottom of my browser window.  I have to scroll down past all the vertical white spce to click on the insert image button.

    if all you need is have mapviewer render the style and place it next to your theme control, you can probablly just issue a regular map request with only 1 feature and specify the style to be used on that feature. For instance, if you just want to show the M.STAR marker style, you can issue a request containing only the center point and specify the render style for the center point as M.STAR. you can also specify the exact width/height you want for the final 'map'. Yes if you issue a legend-only request mapviwer adds white space to it and ignores the width/height attributes.
    finally, we will add your last two items into our wish list. thanks.

  • Default Stroke for Inserted Image?

    When I import a new image into a site in iWeb '08, It (by default) puts a 10 pt gray stroke around the image.
    Is there any way to change that default (say make it 4 pt gold stroke instead)?

    Sure, just set a CSS rule for that image to change the pointer. Give the image a distinct ID, like "imageLink" and then create a rule like this:
    img #imageLink {
         cursor: pointer;
    If you need IE 5.5 support (or below), use this rule:
    img #imageLink {
         cursor: hand;
         cursor: pointer;
    You should be aware though that the "hand" property for cursor is early IE specific and won't pass CSS validation; for it to work properly cross-browser be sure it comes first. Again, use this second rule only if you need way-backwards compatibility.
    Best - Joe
    Joseph Lowery
    Author, Dreamweaver CS4 Bible

  • Creating a script for inserting images

    I am new to the scripting concept, so please forgive me when I use incorrect terminology.
    I would like to create a script that will automatically place images in my InCopy document. Basically I want to type the names of image files in an InCopy document then run a script that will replace the name of the file with the actual image (either as an embedded image or as an image in a graphics frame, although the graphics frame might not work if the document isn't linked to an InDesign document.)
    I'm assuming I'd have to identify the image name in some way (slashes or something before and after) and during the script I'd have to identify where to find the given images, such as which folder they are in.
    Is this possible in InCopy?
    Eventually, these InCopy documents will be used in InDesign. Would it be better/faster to use a script to import these images into InDesign instead of InCopy?
    (In case the information is important, the images are all either .tif files or .eps files.)
    Also, how do I find someone who can write this script for me? I'm assuming there are freelance programmer people out there... how do I find one?
    Thanks for any advice/help you can give me!

    senza wrote:
    this is ok, this i understand now. But where to tell which schema for which user?I don't understand this question. You create a synonym in your own schema for the object you want a synonym for...
    so instead of referencing
    select * from scott.empyou would create a synonym for scott.emp, so you can do
    select * from emp

  • Inserting image into table

    hi,
    i m create table, then create procedure, procedure is successfully compile, but when i m trying to insert image into table it error out.
    for inserting image i go with
    EXECUTE insert_image_file(1,'C:\sunset.jpg');
    sunset.jpg is image which i want to insert in table, and which is present on 'c drive'.
    when execute the following error are shown
    ORA-22285: non-existent directory or file for FILEOPEN operation
    ORA-06512: at "SYS.DBMS_LOB", line 635
    ORA-06512: at "SCOTT.INSERT_IMAGE_FILE", line 26
    ORA-06512: at line 1
    how to solve it.
    regards
    prashant

    Prashant wrote:
    CREATE OR REPLACE PROCEDURE insert_image_file (p_id NUMBER, p_image_name IN VARCHAR2)
    ...snipped...Not very nice code... why create an empty image row, then lock it (it is already locked by the uncommitted insert statement), and then update it again? Not very efficient or sensible.
    image is on local machine.When a row is created on the server from user input on some PC, who supplied that input? Who read the user's keyboard input on that PC to obtain the values for the columns for the row to create?
    Did PL/SQL read the keyboard of that remote PC? Of course not. The client program on that PC read the keyboard input. It then made a client call to the Oracle server. It supplied the data entered via the keyboard by the user to the Oracle server (using a PL/SQL call or using a SQL statement call to Oracle).
    Now why would a local image data on that PC be treated any differently than the keyboard data on that PC? How can you expect PL/SQL code running on the Oracle server, to read that image data from the remote PC when the same PL/SQL code is incapable of reading keyboard input from that very same PC?
    You need to review your understanding of client-server and how it pertains to using Oracle within client-server architecture.

  • Inserting images to mark text boundaries

    Ive added text to a JTextPane from a file.
    and by mouse click ive inserted character
    to mark the boundaries of the text.
    instead of character ive to do with images
    for marking the segment boundaries.
    please suggest me some method for inserting
    images in TextPane for marking boundaries

    Sorry Andre..Still im not getting what you are saying.. im trying to do like this..Could u pls suggest me where i went wrong..Im inserting the icon directly to textpane..rather than to label nd inserting label to textpane bcos label with image cant be retained when mouse is clicked over several times in textpane....
    import java.awt.Cursor;
    import java.awt.Image;
    import java.awt.Point;
    import java.awt.Toolkit;
    import java.io.*;
    import java.util.Enumeration;
    import java.util.Vector;
    import javax.swing.JComponent;
    import javax.swing.JFrame;
    import javax.swing.JInternalFrame;
    import javax.swing.JLabel;
    import javax.swing.JPanel;
    import ncst.pgdst.*;
    import java.awt.Color;
    import javax.swing.ImageIcon;
    import javax.swing.text.*;
    import com.sun.org.apache.xerces.internal.impl.io.UTF8Reader;
    import java.util.Collection;
    import java.util.Iterator;
    import java.util.StringTokenizer;
    import java.awt.BasicStroke;
    import java.awt.Color;
    import java.awt.Graphics2D;
    import java.awt.geom.Ellipse2D;
    import java.awt.geom.Line2D;
    import javax.swing.text.DefaultStyledDocument;
    public class EditFormGui  extends javax.swing.JFrame{
        private javax.swing.JMenu fileMenu;
        private javax.swing.JMenuBar jMenuBar1;
        private javax.swing.JScrollPane jScrollPane1;
        private javax.swing.JLabel labelModes;
        private javax.swing.JPanel leftPanel;
        private javax.swing.JMenuItem loadRST;
        private javax.swing.JButton paraSegment;
        private javax.swing.JMenuItem quit;
        private javax.swing.JMenuItem save;
        private javax.swing.JButton saveSegmentMode;
        private javax.swing.JButton editSegment;
        private javax.swing.JButton showStructure;
        private javax.swing.JButton showText;
        private javax.swing.JMenu structureMenu;
        private javax.swing.JTextPane textPane;
        private javax.swing.JPanel textPanel;
        private boolean segmentFlag = false,debug=true;
        private UserText userText=new UserText();
        private JPanel structureframe=new JPanel();
        private javax.swing.JTabbedPane jTabbedPane;
        private java.util.Vector pNodesVector = new java.util.Vector();
        private javax.swing.JComboBox relationList;
        private javax.swing.JFrame relationChooserFrame = new javax.swing.JFrame();
        private javax.swing.JScrollPane relationScrollPane = new javax.swing.JScrollPane();
        private JLabel label_image;
        ImageIcon icon;
        Cursor c;
        String[] store;
        int posX_icon,posY_icon;
        Point iconPos;
        Vector iconPositions;
        public EditFormGui() {
            initComponents();
        public void initComponents()
            jTabbedPane = new javax.swing.JTabbedPane();
            textPanel = new javax.swing.JPanel();
            iconPositions=new Vector();
            saveSegmentMode = new javax.swing.JButton();
            editSegment=new javax.swing.JButton();
            showText = new javax.swing.JButton();
            showStructure = new javax.swing.JButton();
            labelModes = new javax.swing.JLabel();
            jScrollPane1 = new javax.swing.JScrollPane();
            jScrollPane1.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS);
            textPane = new javax.swing.JTextPane();
            textPane.setEditable(false);
             icon = new ImageIcon("F:/images/division.jpg");
             label_image = new JLabel(icon);
            jMenuBar1 = new javax.swing.JMenuBar();
            fileMenu = new javax.swing.JMenu();
            loadRST = new javax.swing.JMenuItem();
            save = new javax.swing.JMenuItem();
            quit = new javax.swing.JMenuItem();
            structureMenu = new javax.swing.JMenu();
          Toolkit tk = Toolkit.getDefaultToolkit();
          Image image =tk.getImage("F:/images/del.jpg");
          c= tk.createCustomCursor(image , new Point(0,0), "F:/images/del.jpg");
            setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
            saveSegmentMode.setText("Save Segment");
            saveSegmentMode.addActionListener(new java.awt.event.ActionListener() {
             public void actionPerformed(java.awt.event.ActionEvent evt) {
               saveSegmentModeActionPerformed(evt);
            org.jdesktop.layout.GroupLayout textPanelLayout = new org.jdesktop.layout.GroupLayout(textPanel);
            textPanel.setLayout(textPanelLayout);
            textPanelLayout.setHorizontalGroup(
                textPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(textPanelLayout.createSequentialGroup()
                  .addContainerGap()
                    .add(textPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 337, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                                .add(51,51,51)
                                .add(saveSegmentMode)
                                .addContainerGap(36, Short.MAX_VALUE)                               
           textPanelLayout.setVerticalGroup(
                textPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(textPanelLayout.createSequentialGroup()           
                .add(textPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                        .add(textPanelLayout.createSequentialGroup()
                            .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 211, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(49, 49, 49)
                            .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED))
                        .add(textPanelLayout.createSequentialGroup()
                            .addContainerGap(43, Short.MAX_VALUE)
                            .add(saveSegmentMode)))
                    .addContainerGap(43, Short.MAX_VALUE))        
            showText.setText("Text");
            labelModes.setText("Modes: ");
            showStructure.setText("Structure");
            jTabbedPane.add(textPanel);
            jTabbedPane.setTitleAt(0,"Text");
            showStructure.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    showStructureActionPerformed(evt);
            textPane.addKeyListener(new java.awt.event.KeyAdapter() {
                public void keyTyped(java.awt.event.KeyEvent evt) {
                    textPaneKeyTyped(evt);
            textPane.addMouseListener(new java.awt.event.MouseAdapter() {
                public void mouseClicked(java.awt.event.MouseEvent evt) {
                    textPaneMouseClicked(evt);
                   public void mouseEntered(java.awt.event.MouseEvent evt) {
                    textPaneMouseEntered(evt);
                    public void mouseExited(java.awt.event.MouseEvent evt) {
                    textPaneMouseExited(evt); 
            jScrollPane1.setViewportView(textPane);
            fileMenu.setText("File");
            loadRST.setText("Load RST file");
            loadRST.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    loadRSTActionPerformed(evt);
            fileMenu.add(loadRST);
            save.setText("Save RST");
            save.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    saveActionPerformed(evt);
            fileMenu.add(save);
            quit.setText("Quit");
            quit.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    quitActionPerformed(evt);
            fileMenu.add(quit);
            jMenuBar1.add(fileMenu);
            structureMenu.setText("Structure");
            jMenuBar1.add(structureMenu);
            setJMenuBar(jMenuBar1);
            org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
                    getContentPane().setLayout(layout);
                    layout.setHorizontalGroup(
                        layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                        .add(layout.createSequentialGroup()
                            .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                .add(layout.createSequentialGroup()
                                    .add(26, 26, 26)
                                .add(layout.createSequentialGroup()
                                    .addContainerGap()
                                    .add(jTabbedPane, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
                            .addContainerGap())
                    layout.setVerticalGroup(
                        layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                        .add(layout.createSequentialGroup()
                            .addContainerGap()
                            .add(23, 23, 23)
                            .add(jTabbedPane, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
            textPane.setText("This seems to be an interesting exercise. I will surely learn swing now.");
            userText = new UserText(textPane.getText());
            pack();
            validate();
        private void saveSegmentModeActionPerformed(java.awt.event.ActionEvent evt) {                                               
            String textWithPipes= new String(textPane.getText());
            System.out.println("Text with pipes"+textWithPipes);
            userText.setUserText(textWithPipes);
            showStructure();
        private void showStructureActionPerformed(java.awt.event.ActionEvent evt) {
            showStructure();
        public void showStructure()
                 int count=0;
               int totcount=iconPositions.size();
               java.util.Iterator iter = iconPositions.iterator();
              store=new String[totcount];
              try
               String usertxt=userText.getTextWithSegment();
                      char[] usrtxt_chararr=usertxt.toCharArray();
                      System.out.println("Character array Usertextlength"+usrtxt_chararr.length);
                      int pt;
                      pt=0;
              while (iter.hasNext()) {
                          String obj=iter.next().toString();
                          int itervar=Integer.parseInt(obj);
              String subst=usertxt.substring(pt,itervar);   
              pt=itervar+1;
                store[count]=subst;
                 count++;
               catch(Exception e) {}
                   for(int i=0;i<store.length;i++)
                        System.out.println("Store Array Elements"+store);
    structureframe=new Rstmain.gui.ModifyS(store);
    structureframe.setVisible(true);
    jTabbedPane.add(structureframe); //Adding Structure frame
    jTabbedPane.setTitleAt(1,"Structure");
    validate();
    private void textPaneKeyTyped(java.awt.event.KeyEvent evt) {                                 
    if (segmentFlag){
    textPane.setEditable(false);
    private void textPaneMouseClicked(java.awt.event.MouseEvent evt) {                                     
    textPane.setEditable(true);
    int caretpos=textPane.getCaretPosition();
    System.out.println("Caret inserting positions"+caretpos);
    iconPositions.add(caretpos);
    // textPane.insertComponent(label_image);
    textPane.insertIcon(icon);
    textPane.setEditable(false);
    private void textPaneMouseEntered(java.awt.event.MouseEvent evt) {                                     
    private void textPaneMouseExited(java.awt.event.MouseEvent evt) {                                     
    setCursor(null);
    private void loadRSTActionPerformed(java.awt.event.ActionEvent evt) {                                       
    File file;
    SimpleInput sin;
    javax.swing.JFileChooser fd;
    fd = new javax.swing.JFileChooser(new File("."));
    fd.setDialogTitle("Open File...");
    int action = fd.showOpenDialog(this);
    if (action != javax.swing.JFileChooser.APPROVE_OPTION) {
    return;
    file = fd.getSelectedFile();
    try {
    sin = new SimpleInput(file);
    StringBuffer line = new StringBuffer("");
    textPane.setText("");
    while (!sin.eof()) {
    line.append(sin.readLine());
    textPane.setText(line.toString());
    textPane.setEditable(false);
    userText = new UserText(line.toString());
    catch (Exception e) {
    javax.swing.JOptionPane.showMessageDialog(this,
    "Sorry, some error occurred:\n" + e.getMessage());
    private void saveActionPerformed(java.awt.event.ActionEvent evt) {                                    
    File file;
    javax.swing.JFileChooser userFile;
    userFile = new javax.swing.JFileChooser(".");
    userFile.setDialogTitle("Save Text As...");
    int action = userFile.showSaveDialog(this);
    if (action != javax.swing.JFileChooser.APPROVE_OPTION) {
    return;
    file = userFile.getSelectedFile();
    if (file.exists()) {
    action = javax.swing.JOptionPane.showConfirmDialog(this,
    "Replace existing file?");
    if (action != javax.swing.JOptionPane.YES_OPTION)
    return;
    try {
    PrintWriter out = new PrintWriter(new FileWriter(file));
    String contents = textPane.getText();
    out.print(contents);
    if (out.checkError())
    throw new java.io.IOException("Error while writing to file.");
    out.close();
    catch (java.io.IOException e) {
    javax.swing.JOptionPane.showMessageDialog(this,
    "Sorry, an error has occurred:\n" + e.getMessage());
    private void quitActionPerformed(java.awt.event.ActionEvent evt) {                                    
    System.exit(0);
    public static void main(String args[]) {
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    System.out.println("Inside run");
    new EditFormGui().setVisible(true);
    And this is the UserText classimport com.sun.org.apache.bcel.internal.classfile.JavaClass;
    public class UserText{
    int countpipe;
    String userText="";
    java.util.Vector segmentinfo = new java.util.Vector();
    public UserText(String input) {
    userText = input;
    public UserText(){}
    public int getNumberOfSegments()
    return segmentinfo.size();
    public void addSegment(int endIndex){
    int i = 0;
    segmentinfo.add(endIndex);
    public void setUserText(String textWithPipes)
    int indexOfPiping, j=0 ;
    StringBuffer temp = new StringBuffer(textWithPipes);
    segmentinfo.add(j);
    for (int i = 0; i < textWithPipes.length();i++)
    j = textWithPipes.indexOf('|',j);
    segmentinfo.add(j);
    for (int k = 0; k < textWithPipes.length();k++)
    if(textWithPipes.charAt(k)=='|')
    countpipe++;
    userText = temp.toString();
    public String getTextWithSegment(){
    return userText;
    public String getTextWithoutSegment(){
    java.util.StringTokenizer st = new java.util.StringTokenizer(userText,"|");
    StringBuffer temp = new StringBuffer();
    while(st.hasMoreTokens())
    temp.append(st.nextToken());
    return temp.toString();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      

  • A Simple Question... inserting image into JTextPane...

    Well my problem is very simple (but not for me). Before I explain it, please take a look at a simple class...
    public class Window extends JTextPane {
        Window() {
            super();
        }// Window
        public void appendText(String s,Color col) throws BadLocationException {
            StyledDocument sd = getStyledDocument();
            SimpleAttributeSet attr = new SimpleAttributeSet();
            StyleConstants.setForeground(attr,col);
            sd.insertString(sd.getLength(),s,attr);
          *     THE POINT - what should I write here, please consult description followed by the class.
        } //appendText
    } //classThe appendText method simply appends the text in text pane with desired color. Now I want to know what should I write at point THE POINT so that at end of appended string an icon (suppose end.gif) is added and is displayed in text pane. Simple?
    Stay happy,
    fadee

    Dear Fadee,
    here is a small programe for inserting images into JTextPane;
    find this comment and start
    /*All Code In this Button Action*/if you need any thing feel free to tell me,
    i'm with you brother, i'll do my best :O)
    -Best regards
    mnmmm
    * Fadee.java
    * Created on June 7, 2002, 1:13 AM
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.color.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.text.*;
    * @author  Brother Mohammad, Cairo, Egypt.
    * @version
    public class Fadee extends javax.swing.JFrame {
        JTextPane   tp;
        JButton     b;
        StyledDocument sd;
        SimpleAttributeSet attr;
        public Fadee() throws BadLocationException {
            b = new JButton("Press");
            tp = new JTextPane();
            b.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    /*All Code In this Button Action*/
                    try {
                        sd = tp.getStyledDocument();
                        attr = new SimpleAttributeSet();
                        /*get default style*/
                        Style def = StyleContext.getDefaultStyleContext().
                                            getStyle(StyleContext.DEFAULT_STYLE);
                        /*add style for text default style*/
                        Style regular = tp.addStyle("regular", def);
                        StyleConstants.setFontFamily(def, "SansSerif");
                        StyleConstants.setAlignment(def, StyleConstants.ALIGN_CENTER);
                        StyleConstants.setForeground(def, Color.RED);
                        /*add style for icon create as many as icons you have
                         and don't forget to resize the photo at small size
                         to fit with font size*/
                        Style s = tp.addStyle("icon", regular);
                        StyleConstants.setAlignment(s, StyleConstants.ALIGN_JUSTIFIED);
                        StyleConstants.setIcon(s, new ImageIcon("d:\\My Photo.GIF"));
                        /*here is what user will see*/
                        sd.insertString(sd.getLength(), "Allah Akbar ", tp.getStyle("regular"));
                        sd.insertString(sd.getLength(), " ", tp.getStyle("icon"));
                    } catch (BadLocationException x) {
                        x.printStackTrace();
            getContentPane().setLayout(new BorderLayout());
            getContentPane().add(b, BorderLayout.NORTH);
            getContentPane().add(tp, BorderLayout.CENTER);
            setSize(500, 500);
            setVisible(true);
        public static void main(String args[]) {
            try {
                Fadee f = new Fadee();
            } catch (BadLocationException x) {
                x.printStackTrace();
    }

  • Adobe premiere elements 12 - how to create menu bar action for my inserted image button

    adobe premiere elements 12 - how to create menu bar action for my inserted image button without using their movie menu theme

    forbemag
    I do not think that I am completely focused into this completely, so let us see if the following is going to help.
    You are going to need a base for your button. When you mention "image" button, I am assuming that you are using that term to differentiate between a text button and a thumbnail type button.
    The menus (main and scene) take their origin in .psd files on the hard drive and strict nomenclature and structure for Layers Palatte. And, the buttons on the menus trace back to the menu markers on the Timeline, main menu marker and order of placement of scene markers. The scene thumbnail will only appear when there is a scene marker on the Timeline to which it.
    In view of all that
    Where have you already inserted this "image (button)"...into the Layers Palette of a Photoshop document or other? Is this "image (button)" in a structured Layer Group in the Layers Palette with sublayer groups, text layers, graphic/background layer"?
    Let me give you an example
    If you have a button (with thumbnail) on the main menu and you want that to open to a specific scene in your movie, then you use a main menu marker on the Timeline at the spot that you want that button to target.
    If I am getting closer to what you seek, then please further clarify the DVD navigational envisioned scheme.
    Thanks.
    ATR
    Add On...I did not see the exchanges between us and SG until after I had posted mine. I thought that your discussions were concluded. Please excuse the interruption.

  • Hashtable for multi part form to insert image and details to database:)

    Hey guys do you have any samples on using hashtable in multipart form to insert image as well as details into database?:)
    Oh it is because my form is using multipart from that enbales me to upload/Insert image into my database.
    Howerver, I also need to insert other details into my database such as productid, ProdName, unitprice.....
    Hence, My tutor suggested using hashtable.
    However, I do not understnd.
    Do you guys have any samples regarding on this?
    Thanks
    :D

    Cathy_Latte wrote:
    However, I do not understnd. More specifically: you do not understand how to use Maps? If so, just go through a book/tutorial on that subject. In fact you should have consulted your tutor or classmates for more information and you're here at a JSP/JSTL forum at the wrong place (you have a problem with Java in general, not with JSP), but OK, here's a link: [http://google.com/search?q=hashmap+tutorial+site%3Asun.com].

  • "Use presets for responsive layout" not working in Chrome

    I am building a responsive website. I am going to have parts of the website animated using Edge Animate. I will make the animation and then insert it into a div in the responsive website I am building.
    The Adobe Edge animation has a width of 100%, so that it resizes according to the area that it occupies the full width of the div no matter how wide that div may be in px.
    It is all working fine, but:
    I have an image in the Edge animation that is center aligned. It must stay center aligned no matter what width the animation ends up being.
    Within Adobe Edge, in Properties, in Position and Size, there is a option where, if you hover your mouse cursor over the top right button a tool tip says "Use presets for responsive layout"
    With the image on the stage selected, I can click on the "Use presets for responsive layout" button and then choose "Centre background Image".
    It works perfectly in all browsers accept Chrome (even IE is playing ball this time). In chrome the width of the image stretches out as the div stretches out..
    The "Centre background Image" setting says that it won't scale the image. But in Chrome it does.
    What can I do to "tell" Edge Animate to center the image but not scale it in the Chrome browser?
    I can see that in the image properties it is set to Background image x axis and y axis 50%. And the width is set to pixels. But in Chrome, the image stretches.
    If you go to http://www.brainstormadvertising.co.uk/demo/services.html you will see what I mean. The circle image is centering BUT stretching in chrome browsers while centering nicely and NOT stretching in other browsers.

    Thank you for your reply Josh. But the point of this setting in Edge Animate is that you can set it up that the background image is center aligned and does not scale. Yet it produces code that gives the width as 21.72%.
    A little further along I see background-size: 48px; .  This is correct.
    So all the browers are reading background-size: 48px; as the scale measurement but Chrome is reading the width only, not the background-width. So this "Use presets for responsive layout" works in all browsers except chrome.
    I don't know how to change that code after the artwork has been published. I can see the code using Firebug, but where do I change it in my code on my computer before uploading to the server?
    I have reported this bug to Adobe.
    Please see the attachment. You can see where all the settings are made and where I am getting a problem.

  • Using local/testing server with cs5 inserting images look fine in the split screen but do not show

    Hi
    If I open example: header.php and insert any photo jpeg/.html ecs i can see the images in the split screen but not in the browser if i save then refresh. I am able to make any change to the code ecs. and they are reflected just fine. I have tried this with my fireworks images .html and when that did not work i tried a strait jpeg off the desktop. This all did not work. I have deleted the local server then step by step created a new one via devnet instruction. This did not work! everything looks fine i even tried in 3 sep browsers with 0 luck....There is no remote server connected at this time because i am making a child theme for my current site. After all changes are done we will the ftp the word press files to site and change.
    Ps i even started over from scratch with 0 positive affects....

    After a lot of pain!!!!!!! the issue is fixed lol After 3 weeks I have overlooked the obvious !!! so the simple fix was the path of the image. Yes i feel stupid 10 years in lol....
    Apparently dreamweaver cs 5 will not use the full path when inserting images into the page example: If you drag the image out of your assets folder or however you do it, DW will give you a path like this <img src="images/glass.jpg" width="800" height="729"> This is not the full path and when your pist!!! you cant see things like that ;( so the image path should look like this:
    <img src="wp-content/themes/adszoom/images/glass.jpg" width="800" height="729">
    also in the html files example of bad then good!
    <!--======================== BEGIN COPYING THE HTML HERE ==========================-->
    <img name="navigation" src="navigation.gif" width="1000" height="50" border="0" usemap="#m_navigation" alt="">
    <map name="m_navigation">
      <area shape="poly" coords="804,7,994,7,994,47,804,47,804,7" href="http://adszoom.com/699-2/" title="SEARCH BY CATEGORIES FOR CLASSIFIED ADS" alt="SEARCH BY CATEGORIES FOR CLASSIFIED ADS" >
      <area shape="poly" coords="602,8,792,8,792,48,602,48,602,8" href="http://adszoom.com/wp-admin/edit.php/" title="VIEW OR EDIT YOUR CLASSIFIED ADS" alt="VIEW OR EDIT YOUR CLASSIFIED ADS" >
      <area shape="poly" coords="405,8,595,8,595,48,405,48,405,8" href="http://adszoom.com/post-an-ad/" title="NEW CLASSIFIED AD POST" alt="NEW CLASSIFIED AD POST" >
      <area shape="poly" coords="206,8,396,8,396,48,206,48,206,8" href="http://adszoom.com/help/" title="HELP WITH YOUR CLASSIFIED ADS" alt="HELP WITH YOUR CLASSIFIED ADS" >
      <area shape="poly" coords="3,9,193,9,193,49,3,49,3,9" href="http://adszoom.com/" title="HOME VIEW CLASSIFIED ADS" alt="HOME VIEW CLASSIFIED ADS" >
    </map>
    <!--========================= STOP COPYING THE HTML HERE =========================-->
    </body>
    NOW THE GOOD!
    <!--======================== BEGIN COPYING THE HTML HERE ==========================-->
    <img name="navigation" src="wp-content/themes/adszoom/images/navigation.gif" width="1000" height="50" border="0" usemap="#m_navigation" alt="">
    <map name="m_navigation">
      <area shape="poly" coords="804,7,994,7,994,47,804,47,804,7" href="http://adszoom.com/699-2/" title="SEARCH BY CATEGORIES FOR CLASSIFIED ADS" alt="SEARCH BY CATEGORIES FOR CLASSIFIED ADS" >
      <area shape="poly" coords="602,8,792,8,792,48,602,48,602,8" href="http://adszoom.com/wp-admin/edit.php/" title="VIEW OR EDIT YOUR CLASSIFIED ADS" alt="VIEW OR EDIT YOUR CLASSIFIED ADS" >
      <area shape="poly" coords="405,8,595,8,595,48,405,48,405,8" href="http://adszoom.com/post-an-ad/" title="NEW CLASSIFIED AD POST" alt="NEW CLASSIFIED AD POST" >
      <area shape="poly" coords="206,8,396,8,396,48,206,48,206,8" href="http://adszoom.com/help/" title="HELP WITH YOUR CLASSIFIED ADS" alt="HELP WITH YOUR CLASSIFIED ADS" >
      <area shape="poly" coords="3,9,193,9,193,49,3,49,3,9" href="http://adszoom.com/" title="HOME VIEW CLASSIFIED ADS" alt="HOME VIEW CLASSIFIED ADS" >
    </map>
    <!--========================= STOP COPYING THE HTML HERE =========================-->
    </body>
    THIS LINE IS YOUR ISSUE
    <img name="navigation" src="wp-content/themes/adszoom/images/navigation.gif" width="1000" height="50" border="0" usemap="#m_navigation" alt="">
    Ok thanks and if there are any issues with dw please ask: [email protected]

  • I am trying to determine the new project preset for multi-camera video shot as follows:  3 Canon camcorders, main shot is DV (tape) (720x480), b-roll is DVD (mini-disk) (720x480), additional b-roll is AVCHD (1920x1080).  Film is from a wedding, DV contain

    I am trying to determine the new project preset for a multi-camera video shot as follows:  3 Canon camcorders,
    Main shot is DV (tape) (720x480, 29fps) - ceremony and reception
    b-roll is DVD (mini-disk) (720x480, 29fps) - bride preparations
    additional b-roll is AVCHD (1920x1080, 29fps) - groom preparations and misc all day ceremony and reception. 
    Film is from a wedding, DV contains main footage so I assume it will need to be the base.  I am planning to use the preset for DV-Widescreen.  Is there a better option?  I'm concerned about playback as the three appear to have different PAR.  I'm using Premiere Elements 10 on W8.
    Ultimately this will be burned for two formats - one for a DVD that can be watched on a widescreen TV, second for a short clip trailer to go on vimeo.
    (And no I won't be doing this again for a wedding that I shoot.)

    VDRAVES
    Please review since I am not sure how you obtained Video 3 tall when you scaled Video 3 with Constrain Proportions in effect.
    Before
    After
    It becomes a zoomed in effect to get rid of the black borders. But, there is no tall and thin involved anywhere.
    And, after the Scale increase, you can always click on the screen and move the image around a bit
    (without overdoing it to get black borders again).
    After and an adjust
    Please let us know if you are OK with the information above.
    Thank you.
    ATR

  • When inserting image how do I force inline CSS not image tags?

    When I insert an image to my page layout it always uses html width= and height= tags
    e.g. <img src="images/wordpress.jpg" width="125" height="112">
    This is driving me nuts
    (I thought these tags were pretty old fashioned for current doctypes. Why does dreamweaver continue to use them?)
    I want inserted images to be shown with inline CSS
    e.g.  <img src="images/wordpress.jpg" style="width:125px; height:112px;">
    I can then more easily add more CSS like padding, floats etc as needed.
    Any ideas how I set this up as a default or quickly convert?
    (I dont really want to add lots of unique image classes to a style sheet)
    many thanks!
    Dreamweaver CS6

    Image height & width values are not deprecated.  Unless you're building a responsive web site, it is usually better to have these attributes stated in the HTML.
    But when I don't want them, I do the following:
    Insert > Image > browse to file...
    On the properties panel, I delete the width and height values, hit Enter.
    Nancy O.

  • How to create a preset for computer output of 1024x768?

    I just upgraded from Premiere Elements 1.0 (yes, 1! :) ) to PE7. I record user group meetings for my local software developers group. We have screen capture at 1024x768 pixels and audio.
    In PE1 I had no trouble bringing this footage in, editing it and exporting it as 1024x768 for viewing online by the members.
    However, I can't seem to find anyway to create a project preset for 1024x768. It seems I can only create SD, HD and similar.
    When attempting to create a custom preset 90% of the values are pre-filled with settings and I can't change them. I see textboxes for the height and width but I can't change them.
    Is this a limitation of PE7? Why in the world can I not create a video any size I want? Without this ability the upgrade is almost useless to me.
    Please let me know because I feel like I must just be missing something.
    Thanks!
    Matt

    Hey Steve,
    Thanks for the reply.
    I did see the 720p preset and this does produce a nice image. The SD preset made the output look muddy and the screen text was unreadable.
    That being said, when importing my media into a project on the 720p preset I get the black letterbox bars on the side.
    I did render a 10 second test area and changed the output size to 1024x768. I was afraid it would squash the entire video, but much to my surprise it just cropped it. So, while I have to work with the letterboxing I can output an actual 1024x768 video. I was also having a little trouble because I was using File - Export Movie to, well, export my movie. When I tried the Share task, set it to PC and changed the settings this was much easier and produced a much better result.
    Thanks for the help!
    FYI, I use PE7 to export it as a wmv. I'm playing with Expression Encoder to then encoded this with VC-1 for Silverlight clients.

  • I receive error when I try to insert Image to Oracle Database v.9i

    My Error is :
    java.sql.SQLException: ORA-00600: internal error code, arguments: [ttcgcshnd-1], [0], [], [], [], []
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:114)
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:208)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:542)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1311)
    at oracle.jdbc.ttc7TTC7Protocol.fetch(TTC7Protocol.java:797)
    at oracle.jdbc.driver.OracleStatement.doExecuteQuery(OracleStatement.java:1608)
    at oracle.jdbc.driver.OracleStatement.doExecute(OracleStatement..java:1758)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1805)
    at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:410)
    and my code is:
    URL url = null;
         InputStream in = null;
         Statement stmt = null;
         OutputStream out = null;
         try {
         url = new URL("file://D:/MyJava~1/classes/javalogo.gif");
              in = url.openStream();
              stmt = con.createStatement();
              // Create the table
              stmt.execute ("create table ImageTable (count varchar2(20), image BLOB)");
              System.out.println("Table created ...");
              // create a blob entry in the table
              stmt.execute("insert into ImageTable values ('two', empty_blob())");
              stmt.execute("commit");
              String cmd = "select image from ImageTable for update";
    /* error this command/*
              ResultSet rset = stmt.executeQuery(cmd);
              System.out.println("Success execute command.");
              while (rset.next()) {
                   //get the Blob locator
                   blob = ((OracleResultSet)rset).getBLOB(1);
                   System.out.println("Get the BLOB locator");
              //get ready to accept binary file
              out = blob.getBinaryOutputStream();
              int chunk = blob.getChunkSize();
              System.out.print("The chunk size is " + chunk);
              byte buffer[]= new byte[chunk];
              int length;
              while ((length = in.read(buffer)) != -1) {
                   out.write(buffer, 0, length); //image file saved.
              con.close();
              out.close();
              stmt.close();
    thank you for your kind
         

    You should try using PreparedStatement instead of Statement while inserting the image - one of the methods like setBytes(. .), setBlob() or setBinaryStatement() of the PreparedStatement should do the trick..
    The setBytes( ) is inefficient in terms of memory -esp for large images -better is to use setBinaryStream( ).
    Shantanu

Maybe you are looking for