Massive copy to system clipboard with vim?

Say I'm editing a program with vim through a terminal (say xterm). Does anyone know how to copy the contents, via left click highlighting, onto the system clipboard (x11) when the content that needs to be copied is physically off the screen? I've tried to arrow up while highlighting but it doesn't work.

toxic, from what I understand from t-dawg's questions is that he wants to emulate what you can do in gvim, but with vim instead.
In gvim, I can click the mouse button; hold; drag downwards and then gvim will start scrolling downwards, whilst highlighting the passing lines. This is how you highlight large amounts of text (greater than what can fit in a single screen at a time) with a mouse.
However, terminals are slightly dumber. Whilst you can highlight areas of text, that's a console function and not something that vim itself is monitoring. Therefore, you can't achieve the same effect with the mouse in vim as you can in gvim.
Of course, vim is perfectly capable of selecting more text than can fit in a single screen. It has a visual mode. Press v and then move down with your cursor keys, et volia - highlighted text.
Now when it comes to shifting this to X11's clipboard, I've never tried (hence the link I gave for possible help). I'm sure it can be done.

Similar Messages

  • System Clipboard with KDE

    Just wondering if anyone else has encountered this.
    I have a bunch of users using an application mostly on either windows, Linux with Gnome and Linux with KDE. Sometimes, and only on KDE, pasting stuff from the System clipboard causes the application to totally freese up (no CPU time is used, but the application becomes totally unresponsive). I have asked the KDE users to switch over to Gnome, but would really like to know the underlying reason for the problem.

    toxic, from what I understand from t-dawg's questions is that he wants to emulate what you can do in gvim, but with vim instead.
    In gvim, I can click the mouse button; hold; drag downwards and then gvim will start scrolling downwards, whilst highlighting the passing lines. This is how you highlight large amounts of text (greater than what can fit in a single screen at a time) with a mouse.
    However, terminals are slightly dumber. Whilst you can highlight areas of text, that's a console function and not something that vim itself is monitoring. Therefore, you can't achieve the same effect with the mouse in vim as you can in gvim.
    Of course, vim is perfectly capable of selecting more text than can fit in a single screen. It has a visual mode. Press v and then move down with your cursor keys, et volia - highlighted text.
    Now when it comes to shifting this to X11's clipboard, I've never tried (hence the link I gave for possible help). I'm sure it can be done.

  • Signed Applet JTextField copy to system clipboard

    Hi all,
    We have a signed and deployed our JAR file that contains our applet following the instructions listed at:
    http://java.sun.com/products/plugin/1.3/docs/rsa_signing.html
    We used Thwate as our CA. All seemed good.
    However any JTextFields that are in our applet cannot access the system clip board. Looking at the source for JTextComponent it should have access to the system clipboard if the securitymanager allows it.
    The strange thing is that if I call getToolkit().getSystemClipboard() from our applets I can access the clipboard and copy to the system clipboard. Even the code in JTextComponent that checks for system clipboard access (canAccessSystemClipboard) works fine when pasted into the applet.
    Why cant a JTextField copy to the clipboard? Has anyone else come across this?

    Juste an idea.... Is your JTextField belonging to the javax.swing.... packages ?
    Or did you compile using some com.ms , ibm.... sun... package ? This could lead to some different implementations.

  • Programatically copy to  System Clipboard

    I'm trying to programatically copy a value from my applet to the system clipboard without much luck. My jars have all been signed and I am able to ctrl-c and ctrl-v to/from the applet/system clipboard. What I need to be able to do is invoke this behaviour from a popup menu. Below is a code snippet:
    public void actionPerformed(ActionEvent event)
                   Object source  = event.getSource();
                   String strValue = source.toString();
                   StringSelection strSelection = new StringSelection(strValue);
                   Toolkit.getDefaultToolkit().getSystemClipboard().setContents( strSelection , strSelection );
                    // at this point I have verified that 't' does indeed contain my item.
                   Transferable t =Toolkit.getDefaultToolkit().getSystemClipboard().getContents(strSelection );
    }When I try to paste into, say notepad, there does not appear to be anything in the clipboard.
    Any idea as to what I'm doing wrong? I'm using 1.5 plugin (but want to move down to 1.4)
    Thanks,
    -Craig Green

    I guess you didn't sign it right or called your method from untrusted (unsigned) code.
    for signing:
    http://forum.java.sun.com/thread.jsp?forum=63&thread=524815
    second post
    for a full trace:
    To turn the full trace on (windows) you can start the java console, to be found here:
    C:\Program Files\Java\j2re1.4...\bin\jpicpl32.exe
    In the advanced tab you can fill in something for runtime parameters fill in this:
    -Djavaplugin.trace=true -Djavaplugin.trace.option=basic|net|security|ext|liveconnect
    if you cannot start the java console check here:
    C:\Documents and Settings\userName\Application Data\Sun\Java\Deployment\deployment.properties
    I think for linux this is somewhere in youruserdir/java (hidden directory)
    add or change the following line:
    javaplugin.jre.params=-Djavaplugin.trace\=true -Djavaplugin.trace.option\=basic|net|security|ext|liveconnect
    for 1.5:
    deployment.javapi.jre.1.5.0.args=-Djavaplugin.trace\=true -Djavaplugin.trace.option\=basic|net|security|ext|liveconnect
    The trace is here:
    C:\Documents and Settings\your user\Application Data\Sun\Java\Deployment\log\plugin...log
    I think for linux this is somewhere in youruserdir/java (hidden directory)

  • Copying to system clipboard

    i m tryin to copy an image to the system clipboard,. the syntax being the usual
    Toolkit.getDefaultToolkit().getSystemClipboard().setContents(selectedImage,null);
    i m not invoking the method      javax.swing.SwingUtilities.invokeLater(new Runnable(){
              public void run()
    will that create a problem? cuz i can run it normally wen i m not

    will that create a problem?Try it and see.

  • Cant copy to system clipboard

    Hi  - And thanks for reading this post.
    Web Premium CS4 /Win XP SP3 2GB RAM etc etc...
    I am stuck ! . I am no longer able to copy to the windows clipboard from PS.
    I can copy some text from a PS document and paste it into another PS document, but I cant paste it into anything else. When I right mouse click into say Notepad or DW CS4 or any other application the option to Paste is always greyed out and unavailable.
    So far I have un-installed PS CS4 and re-installed it to see if that would help. But still not working.
    Anyone seen this or got any suggestions ?
    Thanks.

    First of all, never do a reinstall until you have exhausted the many simpler possible fixes for PS problems.
    Often resetting preferences (which are not changed by a reinstall) fixes many problems. See http://forums.adobe.com/thread/375776?tstart=0
    In this case however it is a continuing, recurring problem with the Windows Clipboard that many have been frustrated by because there is no sure-fire fix.
    Apart from what ZB said sometimes purging the clipboard from within PS does it; sometimes clearing the interfering that M$ Office does, or copying a single character to clear whatever is clogging it. Over the years I have never seen a single effective fix.

  • JTextArea Copy to System Clipboard

    I have written an applet that generates RSA type 1 key pairs. The application version works correctly and outputs to files. The online applet version works but instead of writing to files I write the key data to the JTextArea hoping that it could be copied and pasted into files by the user.
    The catch is that the private key (encrypted) data does not copy correctly when you use CTRL-C and then paste to Notepad. I think it has something to do with the encoded chars causing the copy to malfunction.
    Take a look at the applet and the source code and let me know if you have any ideas about what might work. The main class is KeyJenApplet.java. I have tried JTextPane, JTextField and old TextArea. The old TextArea had popupmenu copy available but it was weird in that it didn't even populate the TextArea entirely when the applet was run. It populated the data much like the copy by only doing a portion of it.
    http://www.cheersdata.com/keyjenapplet.html

    Thanks for the responses.
    I believe Windows does have a scripting language, which may well be the way to go, although so far I'm unfamiliar enough with it to be unsure.
    As for the threads idea, unfortunately, I'm not programming the other application, so that won't work in this case.
    Using java.awt.Robot is a good idea, and it may be the easiest, except that as you point out, the text in the clipboard would have to be broken down into keystrokes, which seems rather awkward and slow.
    The other issue is how to make sure that another app becomes the active window. The Robot can presumably do it by sending keystrokes (like Alt+Tab in Windows), which require that it be the most recently active window--not always a safe assumption. Might there be a safer way?
    Thanks,
    Gregory

  • WebView -  text copied with Crtl/C or Popup Menu not in system clipboard!

    Dear JavaFX users,
    We have embedded JavaFX WebView in a Swing panel. Everything works fine, but we have realized that text selected and copied with Crtl/C or Popup Menu is not in the system clipboard.
    This is quite annoying, and we woulld appreciate any advice or suggestion for solving this issue.
    Thanks in advance,
    Best,
    Jean-Claude Dauphin

    i don't have enough space on my remote server, there are 2 other sites on this server as well.
    What are you using, FREE web hosting?
    For approx $4.95/month you can get unlimited storage and bandwidth:
    http://www.lunarpages.com/hosting-solutions/
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    http://alt-web.com/
    http://twitter.com/altweb

  • Problems copying from PJC to system clipboard

    I am working on a PJC to allow for editing of large text fields (> 64K). I have most of the functionality working fine. However, I am having a problem using cut, copy, and paste.
    Some details, the PJC extends VBean and includes as JTextArea. Our users want a right click menu to provide functionality for cutting, copying, pasting, and spell checking. I was able to get the spell check working using JSpell. I am not able to get the menu entries for cut, copy, and paste to work. I construct a JPopMenu with the appropriate items. When the menu is activated, if the user selects cut, the actionPerformed method executed the cut method of the JTextArea. This does cut the text from the item, however it is not added to the clipboard for use in other items, except those that have the same implementation class of the original item. If the user uses the keyboard (CTRL-X, CTRL-C, or CTRL-V) the selected data is copied to the system clipboard
    Here is the method I used to create the menu items:
      private JMenuItem makeMenuItem(String label, char acceleratorKey)
        JMenuItem item = new JMenuItem(label);
        item.addActionListener(this);
        item.setMnemonic(acceleratorKey);
        item.addKeyListener(this);
        printDebugMessage("Horizontal text alignment = " + item.getHorizontalAlignment());
        item.setHorizontalAlignment(SwingConstants.LEFT);
        printDebugMessage("Horizontal text alignment = " + item.getHorizontalAlignment());
        return item;
      }Here is the actionPerformed method:
      public void actionPerformed(ActionEvent ae)
        String selection = ae.getActionCommand();
        if (selection.equals("Cut"))
          printDebugMessage("Cut selected");
          text.cut();
        else if (selection.equals("Copy"))
          printDebugMessage("Copy selected");
          text.copy();
        else if (selection.equals("Paste"))
          printDebugMessage("Paste selected");
          text.paste();
        else if (selection.equals("Spell Check"))
          printDebugMessage("Spell Check selected");
          doSpellCheck();
      }I read that jar files needed to be signed to interact with the desktop, but when I signed the jar file the results were the same.
    Platform
    10g AS on Solaris 10.1.2.2
    Windows XP (SP2)
    IE7
    Sun plugin 1.5.0_11 (problem also occurs with 1.4.2_06)
    Any insights would be helpful.
    Thanks

    will that create a problem?Try it and see.

  • Copy an image into system clipboard takes too much memory

    Our Swing application copies a java.awt.BufferedImage into the system clipboard. Our image has a size of 1024x768 pixels and a depth of 24 bits per pixel.
    The copy from the image to the system clipboard works, but is very slow and takes too much memory. Before the copy, java.exe uses about 30 MB. After the copy, it uses about 90 MB! However, a 1024x768x3 image should consume only 2,4 MB.
    We did some debugging and it seems the AWT library does several copies of our original image in order to copy it in the system clipboard. I guess that each of these copies takes a lot of memory (probably because of a different format from the original image) and is not immediately garbage collected.
    This is a big issue for our application because the JVM throws an OutOfMemoryError when we try to copy a new image to the system clipboard.
    Here is our code. Do you have any idea? Thanks a lot for your help.
    // Create the image
    BufferedImage image = new BufferedImage(1024, 768, BufferedImage.TYPE_3BYTE_BGR);
    Graphics2D g2 = image.createGraphics();
    drawSomething(g2);
    g2.dispose();
    // Put the image into the system clipboard
    ImageSelection handler = new ImageSelection(image);
    Clipboard clipboard = Toolkit.getDefaultToolkit().getSystemClipboard();
    clipboard.setContents(handler, handler);
    * An implementation of Transferable and ClipboardOwner to be used with
    * images.
    public class ImageSelection implements Transferable, ClipboardOwner {
        private static final DataFlavor flavors[] = {DataFlavor.imageFlavor};
        private Image image;
        public ImageSelection(Image imageToCopy) {
            this.image = imageToCopy;
        // Interface ClipboardOwner
        public void lostOwnership(Clipboard clipboard, Transferable transferable) {
            image = null;
        // Interface Transferable
        public Object getTransferData(DataFlavor flavor) throws UnsupportedFlavorException,
                                                                IOException {
            if (isDataFlavorSupported(flavor)) {
                return image;
            else {
                throw new UnsupportedFlavorException(flavor);
        public DataFlavor[] getTransferDataFlavors() {
            return flavors;
        public boolean isDataFlavorSupported(DataFlavor flavor) {
            return flavor.equals(flavors[0]);
    }

    why dont u use other data structure to store the image , which will take less memory.

  • Copying to the system clipboard

    Hi...
    I am trying to copy the contents of a JPanel to the system clipboard so I can paste it into an app like MS Word. The JPanel just has some lines and dots on it that I've drawn with draw and fillOval.
    I am VERY new to Java so the only way I could figure out to do this was to save the contents of the panel as a .jpg and then wrap it up in a class I created that implements the transferrable interface. This works....and I can paste it into Word and it looks fine on the screen. But when I print it.....it looks very grainy. So I'd like to be able to copy this panel to the clipboard in some other way besides saving it as an image first.
    Is there any other direct way to copy components like a panel with shapes drawn on it to the system clipboard that anyone knows of?
    Thanks in advance!
    Julie

    Thanks for the suggestion. I tried it...but it still looks like crap when I print it.
    I am drawing directly on a Graphics2D object (the exact size I want), then I put into a BufferedImage. Then I save the BufferedImage as a .png, open it back up and copy it to the system clipboard.
    It is just the image quality. Is there a way to manipulate the DPI?
    Thanks again,
    Julie

  • Hi, I was trying to copy and paste a lot of  info for one day on my calendar to another day and an error message popped up saying that the system responded with an error. Msg won't go away I force quit ical

    Need help for trying to unfreeze a message on my ical.  I was trying to copy and paste some appointment info from one day to another on my ical and a message popped up saying the system responded with an error.  All of my info was below the message.  I can't get that message to go away or work on the ical now at all.  I try to force quit ical and have shut down the computer and it still comes up.  Any suggestions?

    K,
    Try removing the com.apple.iCal.plist file from your Macintosh HD/Users/yourusername/Library/Preferences Folder. To find that Library folder, if you are using Lion, use Finder>Go Menu>Depress the "Option" key>Library. Drag the .plist file to your desktop, and log out/in or restart.
    Next, make sure that you are not connected to the internet. Then to to your Macintosh HD/Users/yourusername/Library/Calendars Folder and remove any files with "Cache" as a part of the file name. Use the same method as listed above to get to the correct Library Folder. Log out/in, or restart and check iCal for functionality.

  • How to copy a generic extractor with function module into a new system?

    Dear Gurus,
    i would like to know how i can copy a gneric datasource with function module from one system to the target system.
    Thank you
    Cheers

    Hi Anesh,
    thank you for replying.
    Since the Datasource will have a new new in the new system, i will create a new one.
    Create a generic datasource base on the table is not the problem.
    My problem is how could i copy the FM in the new system?
    If you can help me on that, it will be fine.
    Thanks

  • Massive copy of BW transformation between different source system

    Hi all,
    in my BW I have different source systems. I have mapped several objects to one source system.
    Now I need to copy all the transformation to other source systems. These source system are different instance of ECCs, there are the same extractor in all the systems.
    I can't use the BDLS becouse these move the transformations between the system not copy it.
    I try to create a Transport and using the Conversion of Logical System Names but this change only the objects with source sytems dependencies, it don't change the technical name of transformation, and do not create a tranformation to the new system but overwrite the existing one.
    Do you know if there are some program or some procedure to copy transformation between sourcesystem in BW?
    Thanks in advance
    Mario

    Hi,
    you can do a Retrofit (System copy), Generally, retrofit happens between two different BW systems.
    check with your basis team if the retrofit is possible with in the same BW system but for different clients.
    Note : System copy will overwrite all the objects.
    Regards,
    Sudheer

  • SAP SQL System Copy backup restore method with ADS(Adobe document services)

    Hello all,
    i´m preparing a system copy with ERP 6.0 in windows and SQL server with ADS.
    I have a doubt, can i do the System Copy backup/restore method with ADS??
    or the only method that works is with system export/import in all instances??
    Thank you

    Hi Oscar,
    Is your ADS system separate from your ERP system, or are they on the same server?
    In any case, you can use backup/restore to copy a Java system, but you must also make a system export/import for the Java server components.  The two work in conjunction, so that the export tool doesn't export your whole database, only the components maintained in the filesystem.  If you select the database detach/attach or backup/restore method in the tool when going against the Java system, it will prompt you at the right point in the process to make your Java export as well.
    The caveat is that the Java export requires downtime, so it isn't possible to copy a Java system without impacting system availability, as it is with a pure ABAP system.
    Best regards,
    Matt

Maybe you are looking for

  • Blocking Vendor Payment Using F110

    Hi All, If I run F110 to pay a vendor, block one of the open items for payment, carry out the payment run, and start another payment run for the same vendor, will the open item that was blocked still be blocked? Will I have to unblock it? Thanks, Dek

  • I deleted my "iPod Slection" playlist and now my iPod won't update.

    I don't know exactly how it happened but the songs on my original "iPod Selection" playlist got messed up and so iTunes automatically created another "iPod Selection Playlist" and I didn't want the songs it put in that playlist on my iPod so I delete

  • How to create an Editable report?

    I want to generate one report using BEx Analyser as my client’s requirement. What the client’s requirement is, when he refreshes the query, he wants the query to be get refreshed and another user-editable sheet need to be get created. And the calcula

  • Full & Final settlement

    Dear All Could you please provide me the details  for  full and final settlement  ( Configuration steps )   ? What is test script ? can you provide me any model  templates with regards to sap hr ? Regards RBS

  • Error When trying to install

    I receive the error "Cannot remove older version of quicktime" when i try to install. It also asks me to locate the file QuickTime.msi? Please tell me what i should do. Thanks