-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Copy & Paste #3
Comments
It will most likely be a while before this is added. I know it is a core feature but it involves a lot. I would rather get more done, that way when copy and paste implementation comes around, it can be thought through better. |
Might be worth looking into the HTML5 Clipboard API. It doesn't work as well as it could, but it works in most instances on current browsers. It's better than nothing (until we get better support or resort to ZeroClipboard). Reference: http://www.w3.org/TR/clipboard-apis/ |
@MrSchism In order for copy paste to be implemented, first text selection really needs to be handled by Poe itself, because when tables and images get added, stock js ranges will not be too great to work with. |
I have looked into this in the past regarding OS.js. Since clipboard is considered unsafe, most browsers does not allow this behavior... except IE (shocker... right?). There are Flash solutions for this, but even that is slowly becoming unsusable because of new security policies regarding Flash. |
But you can however create custom keyboard bindings and functions for this pretty easily (but that would only work within Poe). Global copy/paste via OS clipboard however is not that pretty. |
@andersevenrud Yea copy and pasting is horrible when it comes to web browsers. Its been an issue for years, I wonder why the vendors have not done something about it? |
@RyanRiffle It's quite simple. It's considered harmful. If you had complete access to the clipboard you could insert malicious links and/or code (if the implementation has a buffer overflow or something, things go wrong fast!). |
Yeah. Luckily they're working on improving HTML5 APIs to replace the Flash solutions... but there's still no real solution. |
Copy and paste will not be hard to implement now. Text selection now works due to the recent rewrite of the project and change from Coffeescript to Javascript. So now it is just a matter of getting the elements that are selected and detaching them from the DOM and inserting them when necessary. Getting all of the selected words is already in the API as well so piece of cake! |
As a note: The desktop version of Poe will possibly be able to support Copy + Paste using the system clipboard, however the web version will need something more as stated above. At the time of this writing Copy has been implemented but the inverse Paste has not been worked out completely. This is only for internal copy + paste at the moment. |
Provide copy and paste support. At a minimum be able to copy and paste text only without formatting.
The text was updated successfully, but these errors were encountered: