Copy and paste in Swing HTML editor

Hi,
I have two related questions:
1. Is there any detailed documentation on the method insertHTML(HTMLDocument doc, int offset, String html, int popDepth, int pushDepth, HTML.Tag insertTag) in class HTMLEditorKit available? The information included in the API specification is very reduced.
2. Is there any way to do copying and pasting in an HTMLDocument that preserves text format and does not create a new paragraph?
Thanks in advance,
Roberto Moriyon

Hi kdhkdh,
In the typical Mac application, including Safari, you can copy items such as text or pictures by selecting the item to be copied and then either using the Edit menu > Copy or the keyboard shortcut Command-C. Paste is accomplished by selecting the location you wish to paste into and then Edit menu > Paste or the keyboard shortcut Command-V. See this article -
OS X: Keyboard shortcuts - Apple Support
Thanks for using Apple Support Communities.
Best,
Brett L 

Similar Messages

  • When playing flash player based browser games I cannot copy and paste HTML , had no problems doing this with explorer

    I play a browser game, and some times we post battle out results in html in the chat section, where we copy and paste them into a new browser window to view them, this is not possible since I switched to Firefox

    Toddy, see [http://news.cnet.com/8301-30685_3-20004620-264.html?tag=mncol;txt]

  • How to copy and paste text into email without HTML gibberish

    I've had trouble for some time now copying and pasting text into and out of yahoo emails. I can't just copy and paste text, I have to first transfer to Word for Mac and then paste into a yahoo email. Then I end up with what looks like three lines of HTML gibberish at the start of the pasted text each time. Isn't there a clean and direct way of copy and paste of text into and from emails in yahoo? No other email I work with has this problem, and the Safari browser doesn't give this same issue
    == This happened ==
    Every time Firefox opened
    == some recent Firefox update, I think

    I have to agree with bmalmquist.  Need for Speed seems to work great on the Playbook.  I didn't buy the Playbook to play games though.  RIM needs to shift their focus from games to useful and productive apps.  The apps I need to use are either missing very important features, or are just completely missing.  It is somewhat disconcerting to see new apps appear in App World only to discover that the new apps are mostly games.  I'm seeing lots of apps that would help me waste time, but very few that will actually help me be more productive.

  • When trying to copy and paste on my MAC using firefox, I keep coming across a message "your browser security settings don't permit the editor to automatically execute pasting operations". This only happens with firfox, not Safari. any help??

    When trying to copy and paste on my MAC using firefox, I keep coming across a message "your browser security settings don't permit the editor to automatically execute pasting operations". This only happens with firefox, not Safari. any help??

    See:<br />
    http://kb.mozillazine.org/Granting_JavaScript_access_to_the_clipboard
    https://addons.mozilla.org/firefox/addon/852 - AllowClipboard Helper

  • Most compatable file type to use when copying and pasting specially formatted text into html pages?

    Hello,
      I have a simple web site at http://www.psychicmeatloaf.com which is an online poetry journal site. I use files people send me (mostly .doc or .docx) and cut and paste the text from those files into html pages in an older version of Dreamweaver and some of the text has special formatting (like this page: http://www.psychicmeatloaf.com/Chang-poetry.htm ). The best way I have found to maintain the special text formatting is to open the .docx files and "save as a web page" in Word and then open the web page from Dreamweaver and then "Preview the page" in Explorer and copy and paste from the preview into an html page in Dreamveaver. Even using this method, some text will not maintain it's special formatting and for those I just save the page as a .jpg file and use that, because I have no other choice.
      My question is, is there a better way and is there a better file type to work from other than .docx?
    Thanks a milliom,
    George

    neophyte weaver wrote:
    The best way I have found to maintain the special text formatting is to open the .docx files and "save as a web page" in Word and then open the web page from Dreamweaver and then "Preview the page" in Explorer and copy and paste from the preview into an html page in Dreamveaver.
    That's a lot of steps to get to a single end that could be done with a simple copy & paste of the text into code. Like Photoshop and Fireworks, Word writes some very bulky and dirty code. I wouldn't recommend it for direct copy by the method described above.
    I personally copy the text and paste it into code view. It takes a little more work, but I don't get dozens of lines of inline styles added with it and using a preformatted post div (saved and hidden in the code (<!--post block code goes inside-->), I can quickly put title, date, byline and links up with a cut & paste.
    That's just my $0.02 worth
    Also, since nearly EVERYONE will use a different formatting in a Word doc, putting a bunch of differently formatted posts into a page will make it look like one of those ransom notes made of cut out text from different newspapers and magazines.  Better to keep everything in a single format (your format) so it doesn't become an eyesore.
    Message was edited by: Curtis_E_Flush

  • The bar where the html is suppose to show, the new feature of firefox 4 doesn't seem to show it, what do i do when i want to copy and paste it without loading or refreshing the page again?

    i am having problems with not seeing the HTML on the bar because i always look and copy and paste it on things like Facebook and stuff. but now with this new feature, i cannot see or copy or paste it.

    You can find the Copy, Paste, and Cut buttons in the Edit menu and the Edit sub menu in the Firefox menu.<br />
    If you need access to the menu bar then press F10 or press and hold the Alt key down to bring up the "Menu Bar" temporarily.
    You can also find them as toolbar buttons in the toolbar palette in the Customize window and drag them on a toolbar.
    * http://kb.mozillazine.org/Toolbar_customization

  • Automation Folder, Automation Event Editor, Automation copy and paste help

    Hello. I have been reading the copy and paste automation threads and I still have a few questions. First, thanks to whoever posted the option double-click on track background to select all visible automation for that track. Also, thanks to whoever posted the option click an automation node to select all following visible automation nodes.
    Now, how do you select the middle 10 automation nodes in a track with 30 nodes? Many people have stated that the answer is a rubberband selection. This does not work for me. When I click and drag on the track background using the pointer Logic thinks I'm trying to create a new automation node. When I click and drag on the track background using the marquee tool Logic selects the audio and automation data. Then it only pastes the audio only even though I have "move automation with regions" set to ask.
    Some people have recommended the automation folder. When I open the Automation Event Editor and click on the tiny rectangle in the upper left corner I just get a short list of the automation data. Is this right? If so, how do I select the data I want and paste it to another track? Because when I select the automation data for a track and copy nothing seems to happen when I paste.
    Any automation gurus out there willing to help? Please and thank you in advance.

    Hello Pete. Thanks again. It's odd that something so potentially useful is so hard to get to. I guess that is what people are referring to when they say that Logic has a steep learning curve. Is there another way to get to the automation folder? I think that it should have it's own item in the windows menu instead of sharing it with the arrange window and being contextual.
    The copy and paste in the automation folder (automation arrange seems more appropriate as I cannot figure where the folder is) does not work as I expected. For instance, when I select volume automation from a track then option drag it to the pan automation of another, it still copies it to the volume automation. I then have to command click volume then switch to pan and select copy and convert, which makes it MIDI, which you say is not recommended. Will you tell me why TBA (and I assume RBA) is preferred over MIDI based automation? What is the difference exactly? Thank you so much for your assistance.

  • Right - left  scroll in editor makes mouse jump randomly when trying to copy and paste

    Hello,
    Please see attached screen and the red are in bottom right corner
    A right and left scroll bar keeps appearing, I have word wrap turned on. The scroll is very tiny, and I can make it temporarily go away by playing with the widow width, but it always jumps back.
    Why this is irritating is because when i try copy and paste text, it makes the view jump to top of page. How can I make it so it never has a right and left scroll ever!

    Good day!
    use arrow key to move object around but can only do up/down and right left and not foward and backward.
    What do you mean?
    Could you please post a screenshot to illustrate the issue?
    While Photoshop has accumulated 3D features with the last few versions it is originally a 2D image editing program and for a basic Layer there is no »forward« and »backward« (save for the Layer Structure as indicated in the Layers Panel).
    Regards,
    Pfaffenbichler

  • JspSmartUpload Copy and Paste HTML ' and " null Error

    I have this trouble with SmartUpload... my system has no problem with inputtin text information manually with the ' or " character, but if i copy and paste some text from a website page with the ' or " characters, the SmartUpload will prompt with the java.lang.NullPointerException error... The error occurs during the process below
    SmartUpload myUpload = new SmartUpload();
    myUpload.initialize(getServletConfig(), request, response);
    myUpload.upload();
    Is this a bug in SmartUpload??

    SmartUpload is no move available (site is closed).
    Try UploadBean :
    http://www.javazoom.net/jzservlets/uploadbean/uploadbean.html

  • Applications that can copy and paste between Keynote?

    I am looking for both graphic and web appliations that can copy and paste scalable elements between it and Keynote.  I create a lot of graphics in Keynote and I am hoping to find editors that can handle those elements.  I already own PowerPoint, and it does an OK job.  I you have any suggestions, I would like to here it.

    Shapes created in PowerPoint can be placed on to a Keynote slide using copy and Paste.
    Illustrator is the number one vector application and Illustrator files can drag and drop on to the slide.
    The HTML export from Keynote as you have discovered, is only designed to make simple HTML slide shows
    see some free applications here:
    Free vector apps

  • Cut, Copy and Paste + JEditorPane

    I am currently working on a text editor and i have now come to the cut, copy and paste "functions". When i try to compile my code i get:
    1. ERROR in MyMenu.java (at line 42)
    GUI.textarea.cut();
    ^^^
    The method cut() is undefined for the type JEditorPane
    2. ERROR in MyMenu.java (at line 47)
    GUI.textarea.copy();
    ^^^^
    The method copy() is undefined for the type JEditorPane
    3. ERROR in MyMenu.java (at line 51)
    GUI.textarea.paste();
    ^^^^^
    The method paste() is undefined for the type JEditorPane
    The code:
                             else if(event.getActionCommand().equals("Klipp ut")){
                             GUI.textarea.requestFocus();
                               GUI.textarea.cut();
                             else if(event.getActionCommand().equals("Kopiera")){
                             GUI.textarea.requestFocus();
                               GUI.textarea.copy();
                             else if(event.getActionCommand().equals("Klistra in")){
                             GUI.textarea.requestFocus();
                               GUI.textarea.paste();
                             }

    That didn't help me at all. I am trying to run the copy, paste and cut actions from my JMenubar. You can see my Jmenubar class code here.
    // Importerar det n�dv�ndiga
    import java.awt.*; import java.awt.event.*; import javax.swing.*;
    public class MyMenu extends JMenuBar
       // Arkivmenyn
       String fileItems[] = new String [] {"Nytt","�ppna","Spara","Spara som...","Avsluta"};
       char fileShortcuts[] = {'N','O','S','A','P','C','x'};
       char fileAccelerators[] = {};
       // Redigeramenyn
       String editItems[] = new String [] {"�ngra","G�r om","Klipp ut","Kopiera","Klistra in",
          "Rensa","Markera allt"};
       char editShortcuts[] = {'U','R','t','C','P','l','S'};
       char editAccelerators[] = {'Z','Y','X','C','V','\u0000','A'};
       // Konstruktorn
       MyMenu()
            // Namn till Menynraden
                   JMenu fileMenu = new JMenu("Arkiv");
                   JMenu editMenu = new JMenu("Redigera");
                   JMenu helpMenu = new JMenu("Hj�lp");
         // Kollar efter vilken meny som anv�ndaren g�r in p�
              ActionListener printListener = new ActionListener()
                           public void actionPerformed(ActionEvent event)
                             // Detta skall h�nda n�r anv�ndaren g�r in p� Avsluta
                             if(event.getActionCommand().equals("Avsluta")){System.exit(0);}
                             // Nytt
                             else if(event.getActionCommand().equals("Nytt") || event.getActionCommand().equals("Rensa")){
                                  GUI.textarea.setText("");
                             else if(event.getActionCommand().equals("Klipp ut")){
                               GUI.textarea.cut();
                             else if(event.getActionCommand().equals("Kopiera")){
                               GUI.textarea.copy();
                             else if(event.getActionCommand().equals("Klistra in")){
                               GUI.textarea.paste();
                             else if(event.getActionCommand().equals("�ppna")){
                               MyBrowser myBrowser = new MyBrowser();
                                 myBrowser.setVisible(false);
                             // Annars skall denna kodsnutt k�ras
                             else {System.out.println("Menu item["+event.getActionCommand()+"[pressed!");}
         // For-sats f�r att skapa Arkivmenyn
         for (int i=0;i<fileItems.length;i++)
            JMenuItem item = new JMenuItem(fileItems, fileShortcuts[i]);
         item.addActionListener(printListener);
         fileMenu.add(item);
         // Redigera-menyn
    for (int i=0;i<editItems.length;i++)
         JMenuItem item = new JMenuItem(editItems[i], editShortcuts[i]);
    if (editAccelerators[i] > ' ') // M�ste l�ggas till
    {item.setAccelerator(KeyStroke.getKeyStroke(editAccelerators[i],
    Toolkit.getDefaultToolkit().getMenuShortcutKeyMask(),false));}
         item.addActionListener(printListener);
         editMenu.add(item);
         // L�gger in tv� linjer i Redigeramenyn p� plats 2 och 9
    editMenu.insertSeparator(2);
    // L�gger till de skapade undermenyerna i menylisten
    add(fileMenu); add(editMenu); add(helpMenu);

  • Can't copy and paste TOC from MS Word

    I'm working on a book, using Word styles (Word 2007). Word
    generates a table of contents. I would like to copy and paste the
    table of contents into Dreamweaver. When I try to paste I get a
    message that says the document is very long and it would take too
    long to import. It suggests that I copy and paste part of the TOC.
    No luck.
    I've tried to copy and paste the section into another Word
    doc as rich text to remove formatting. I still have the same
    problem. I've tried to Google for an answer, but haven't found one.
    Anyone have any ideas?
    Thanks,
    Denny

    Paste content into Notepad or some other text-only editor
    first. If it
    succeeds, then paste into DW. My guess is that it won't work
    because TOC's
    are MS proprietary critters and thus won't translate to plain
    text or HTML.
    Nancy O.
    Alt-Web Design & Publishing
    www.alt-web.com

  • [solved] icewm copy and paste (terminal)

    copy and paste works perfectly between graphical programms (e.g. abiword and firefox). However if I mark something in xterm I can't copy and paste to another application, like an editor or abiword.
    I don't have this problem in xfce: copy in the terminal and paste somewhere else works.
    What can I do?
    Last edited by mumpf (2008-01-18 21:32:44)

    sorry, but I have a 2-button wheel mouse. I will search some more xsel details myself, thanks.
    Edit: http://www.vergenet.net/~conrad/softwar … el.1x.html Here they are.
    I have replaced xterm by xfce-terminal. Now I can copy and paste without any problems.
    Last edited by mumpf (2008-01-18 21:36:25)

  • How do I copy and paste from one page or file to another page or file - on the same screen?

    How do I copy and paste from one page or file to another - on the same screen?

      Open both of your images in the Editor. Click on the image you want to copy and press Ctrtl+A (select all) followed by Ctrl+C (copy) then click the tab for your other image and press Ctrl+V (paste)
    Alternatively click on your background image then simply drag the second image from the photo/project bin and drop it into the main editor workspace on top of the background image. Use the move tool to position and the corner handles of the bounding box to scale.

  • How to NOT retain formatting when copying and pasting text

    Captivate 7 keeps the formatting from my text sources when I paste into a Text Caption which is not what I need. Anything I could find in the forums where questions relating to "keeping" the source formatting. I don't want this, I want Captivate to keep its text formatting when I paste text into a text caption. I even did a test creating a new project and using one of the Cap 7 themes. If I paste text in the default capture caption style object, it retains the formatting of the copied text source.  I have been working with Captivate 7 since a few months now and, until this morning, when I copied and pasted text from another source into my Captivate Text Caption, it retained the format of my Captivate Text Caption object. This is exactly what I need. How can I get this behavior back?
    I appreciate any help. Thank you.

    Hi there
    Well, first I would report it as undesired behavior and possibly ask for an enhancement that allows us to right-click and paste without formatting. Do this using the link below:
    http://www.adobe.com/go/wish
    For now, you have a couple of options.
    1. Perform a side trip. Open a text editor such as Windows Notepad or Apple Textpad and paste, then copy back to the clipboard. Then paste the text into the caption. (When pasting into the text editor, formatting is stripped)
    2. On Windows machines, you can usually find a clipboard utility that allows you to paste as pure text. In fact, one such application is called PureText.
    PureText Home Page (Note that I have no affiliation with them and nothing to gain if you choose to use the product. Just wanted to make you aware of it.)
    Cheers... Rick

Maybe you are looking for

  • Display image in JFrame

    I am looking for a way to display an image in a jframe. I want to avoid wrapping it into a container..such as a JPanel, JLabel..ect. Does anyone know a way? I seen in the API there is a Graphics function drawImage but I can not get it to work, and tr

  • Encore and Windows 8.1

    So is Encore CS6 working for any of you in Windows 8/8.1?  I was under the impression that it won't, or maybe that's just because Adobe won't bother with it anymore. From Adobe's Encore FAQ's: Encore CS6 is supported on Microsoft® Windows® 7 with Ser

  • How to change date picker display format?

    Default display format is 01-JAN-09 for date picker. How can I change it to Jan 21, 2009 Thank you.

  • New episodes of podast not showing up in itunes

    Hello my podcast in itunes https://itunes.apple.com/fr/podcast/manga-news.com-lemission/id919127007?l=en 2 épisodes my RSS http://feeds.feedburner.com/Manga-news-Lemission 4 épisodes ... when I add my RSS in other plateform or use a podcast software

  • Can't open downloaded game. says need to be administrator. I am. tried 'repair disk permissions/no help...

    Unable to open downloaded game. Says need to be administrator/I am. Repair disk permissions w/disk utility no help...what do I do?