Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-25-2006, 04:29 AM
|
#1
|
Member
Registered: Apr 2003
Location: Vancouver
Distribution: Debian
Posts: 37
Rep:
|
Is there an app like this?
I used to use a Window$ system-tray applet all the time, for reformatting quoted email. I could copy the quoted text to the clipboard, click the applet's icon, and it (a) removed the ">" quote characters and (b) reformatted it (preserving the paragraph breaks).
Is there an applet like this for Linux? If not, is there a way to do the same thing from a script? (Preferably this would work directly with the clipboard, rather than having to save the text as a file each time.) Thanks!
|
|
|
03-25-2006, 03:48 PM
|
#2
|
Member
Registered: Nov 2004
Location: ON, CANADA
Distribution: ubuntu, RHAS, and other unmentionables
Posts: 372
Rep:
|
I don't know of any which are purpose-made made for this, but:
if you have OpenOffice or similat, you could just use the edit/replace text function.
otherwise, you could use vi in a terminal window key-clicks below)
- open a term window
- vi blahblah
- i
- paste text into window
- esc
- :1,$s/>//g
the result won't have any of your >'s ... you can just re-copy&paste it.
Note this is just a simple example... you can build on it to accomplish what you're after..
cheers 
|
|
|
03-30-2006, 05:02 AM
|
#3
|
Member
Registered: Apr 2003
Location: Vancouver
Distribution: Debian
Posts: 37
Original Poster
Rep:
|
Thanks for your reply. Yes, I know how to use search/replace in a text editor... That's not really the problem.
I would like to remove > marks and reformat all paragraphs (join all lines not separated by a blank line) in one operation.
In particular, Yahoo Mail breaks up text like this:
> This is an example of the kind of
> text you see in
> quoted Yahoo Mail messages.
>
> I have no idea why it quotes this way, but I think
> you'll agree, it's pretty dumb.
With the applet I described, I would just:
1. Select & copy the text.
2. Click the applet's system-tray icon.
3. Paste the fixed text, which looked like this (without the hyphens):
- - -
This is an example of the kind of text you see in quoted Yahoo Mail messages.
I have no idea why it quotes this way, but I think you'll agree, it's pretty dumb.
- - -
Then I'd add the writer's initials to each paragraph, e.g.:
JS> This is an example of the kind of text you see in quoted Yahoo Mail messages.
Nice, eh?
I just tried this same process in KDE's Kate text editor. It took over 20 keystrokes (without adding the initials).
I did use Kate's Ctrl+J command to reformat each paragraph---but unfortunately it removes blank lines instead of preserving them. Too bad there isn't a choice about that.
Anyway, thanks for listening. (And if someone involved in one KDE's text-editor projects wants to consider adding this kind of feature, that'd be great!)
|
|
|
All times are GMT -5. The time now is 06:50 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|