Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
Even simply copying text within Zim causes inconvenience with formatting. For instance, try copying part of a heading, then pasting that into a line of normal text: Most users would want the pasted text to take on the formatting of the target location, rather than retaining its formatting from the source location. The workaround, under Linux, is to highlight the source text, which copies it into the X11 "selection" buffer. Then it can be pasted as plain text using the middle mouse button. Unfortunately this workaround would likely apply only to X11-based systems, leaving Windows users with the original issue. Would a Paste As option be practical to add? On 3/26/13, Jaap Karssenberg wrote: > Must say it is mainly a personal preference on my side that this is > how I like the text to look when I paste stuff into an email. If you > have a use case where this formatting is causing problems please let > me know. > > Regards, > > Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
Your assumption is right, my code is in verbatim text. Having the option to have headings transferred to comments would be great, but unfortunately I know less then a bit of python. But even the option to copy/paste without any format would be great. I just start all my headings with a hash, so when copied to my code editor, they are commented automatically. By the way, the headings level 3 and below are already copied with hash tags in front, like e.g., below: Heading level 1 === This is a test Heading level 2 --- This is a test ### Heading level 3 This is a test Heading level 4 This is a test So it seems it is already partially implemented :-) Cheers, Paulo p.s. if I may sneak in an idea for plugin, what about the other way around, a function that converts code (plain text) to verbatim text and commented text (all lines starting with a hash for example) to a headings? Perhaps different heading levels depending on the number of hash tags. Just an idea :-) On Fri 29 Mar 2013 10:50:17 AM CET, Jaap Karssenberg wrote: On Thu, Mar 28, 2013 at 1:22 PM, Paulo van Breugel wrote: For me a clean text copy/paste option would be great. I keep a record of R and shell scripting code in zim. I use headings to structure the code in ZIM. This works great, except that often I want to copy some code from a Zim page to my text editor and I would prefer not to have to remove all the heading format code. My first thought is that the headings in the wiki page should probably transfer to comments in the code. And I assume the actual code in the zim page is formatted as blocks of verbatim text. Continuing that thought you could even define a special copy-paste format that turns all normal text into comments and only leaves verbatim blocks as normal text. Does this make sense for your use case, or am I assuming to much about how you use it ? ( Only complexity would be the different comment styles. Probably you would need a variant that uses "#" for comments and one that uses "//" for comments. ) Regards, Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On Thu, Mar 28, 2013 at 1:22 PM, Paulo van Breugel wrote: > For me a clean text copy/paste option would be great. I keep a record of R > and shell scripting code in zim. I use headings to structure the code in > ZIM. This works great, except that often I want to copy some code from a Zim > page to my text editor and I would prefer not to have to remove all the > heading format code. My first thought is that the headings in the wiki page should probably transfer to comments in the code. And I assume the actual code in the zim page is formatted as blocks of verbatim text. Continuing that thought you could even define a special copy-paste format that turns all normal text into comments and only leaves verbatim blocks as normal text. Does this make sense for your use case, or am I assuming to much about how you use it ? ( Only complexity would be the different comment styles. Probably you would need a variant that uses "#" for comments and one that uses "//" for comments. ) Regards, Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
Hi Jaap, For me a clean text copy/paste option would be great. I keep a record of R and shell scripting code in zim. I use headings to structure the code in ZIM. This works great, except that often I want to copy some code from a Zim page to my text editor and I would prefer not to have to remove all the heading format code. Cheers Paulo On Tue 26 Mar 2013 10:26:10 PM CET, Jaap Karssenberg wrote: On Tue, Mar 26, 2013 at 10:17 PM, Adrian Fita wrote: Well, I'm often finding myself wanting to transfer some of the notes I keep in my personal Zim wiki into my company wiki and it's a nuisance to have to remove the code from the text pasted from Zim. The wiki's markup language doesn't seem to use any of Zim's copy-paste markup. If you know a bit of python it might be worth the effort to add a module with your wiki format. (Btw. there is a preference for the default copy-paste format as well.) -- Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On Tue, Mar 26, 2013 at 10:17 PM, Adrian Fita wrote: > Well, I'm often finding myself wanting to transfer some of the notes I > keep in my personal Zim wiki into my company wiki and it's a nuisance to > have to remove the code from the text pasted from Zim. The wiki's markup > language doesn't seem to use any of Zim's copy-paste markup. If you know a bit of python it might be worth the effort to add a module with your wiki format. (Btw. there is a preference for the default copy-paste format as well.) -- Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On 26/03/13 21:37, Jaap Karssenberg wrote: > On Tue, Mar 26, 2013 at 6:57 PM, Adrian Fita wrote: >> Oh, you're right. The "plain text" indeed outputs the wiki code for the >> headings, bullets and nothing else. I was expecting that in text mode >> even the headings would lose their formatting. So it's not a bug after >> all, but a design decision; ok, fair enough. > Must say it is mainly a personal preference on my side that this is > how I like the text to look when I paste stuff into an email. If you > have a use case where this formatting is causing problems please let > me know. > > Regards, > > Jaap Well, I'm often finding myself wanting to transfer some of the notes I keep in my personal Zim wiki into my company wiki and it's a nuisance to have to remove the code from the text pasted from Zim. The wiki's markup language doesn't seem to use any of Zim's copy-paste markup. -- Adrian Fita ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On Tue, Mar 26, 2013 at 6:57 PM, Adrian Fita wrote: > Oh, you're right. The "plain text" indeed outputs the wiki code for the > headings, bullets and nothing else. I was expecting that in text mode > even the headings would lose their formatting. So it's not a bug after > all, but a design decision; ok, fair enough. Must say it is mainly a personal preference on my side that this is how I like the text to look when I paste stuff into an email. If you have a use case where this formatting is causing problems please let me know. Regards, Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On 26/03/13 19:42, Jaap Karssenberg wrote: > On Tue, Mar 26, 2013 at 6:36 PM, Adrian Fita wrote: >> Thank you, I dind't notice this. But it doesn't seem to work: I selected >> "Text" for the copy format to clipboard and I still get the wiki code >> when pasting in a plain text editor. >> >> Should I file a bug or is there something else that I'm missing. I'm >> using v0.59 on Linux and v0.59 on Windows. On both OSes it's the same. > Please be more specific what wiki code you are talking about. If I > remember correctly the "plain text" output does out put wiki text for > headings, but not for most other things. This is the intended > behavior. > > Regards, > > Jaap Oh, you're right. The "plain text" indeed outputs the wiki code for the headings, bullets and nothing else. I was expecting that in text mode even the headings would lose their formatting. So it's not a bug after all, but a design decision; ok, fair enough. -- Adrian Fita ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
On Tue, Mar 26, 2013 at 6:36 PM, Adrian Fita wrote: > Thank you, I dind't notice this. But it doesn't seem to work: I selected > "Text" for the copy format to clipboard and I still get the wiki code > when pasting in a plain text editor. > > Should I file a bug or is there something else that I'm missing. I'm > using v0.59 on Linux and v0.59 on Windows. On both OSes it's the same. Please be more specific what wiki code you are talking about. If I remember correctly the "plain text" output does out put wiki text for headings, but not for most other things. This is the intended behavior. Regards, Jaap ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp
Re: [Zim-wiki] How to copy-paste from Zim without the wiki code?
Thank you, I dind't notice this. But it doesn't seem to work: I selected "Text" for the copy format to clipboard and I still get the wiki code when pasting in a plain text editor. Should I file a bug or is there something else that I'm missing. I'm using v0.59 on Linux and v0.59 on Windows. On both OSes it's the same. On 26/03/13 19:10, Syv Ritch wrote: > Edit > Preferences > Editing > Default format for copying text to > clipboard: Text > > On Tue, 26 Mar 2013 18:42:23 +0200 > Adrian Fita wrote: > >> Hi. >> >> I'm using the Windows version (I think this works the same in >> Linux) of Zim and when I copy-paste a whole page (or one or more >> paragraphs with formatting) from Zim to a text editor, the copy >> operation outputs also the wiki-code from Zim. How can I avoid this? >> >> Thanks. >> -- >> Fita Adrian -- Adrian Fita ___ Mailing list: https://launchpad.net/~zim-wiki Post to : zim-wiki@lists.launchpad.net Unsubscribe : https://launchpad.net/~zim-wiki More help : https://help.launchpad.net/ListHelp