#Purpose to remove the Enters from the Windows Clipboard while
#copy pasting large bunches of text from pdf files
#tested on WinXP and WinVista. Hint put a shortcut on the Desktop and assign keyboard
#shortcuts mine is AltGr + R
package removeEnters ;
use strict ;
use warnings ;
use Win32::Clipboard ;
main(); #action !!!
sub main
{
local $/; # enable localized slurp mode
my $text = Win32::Clipboard::Get(); #get the text from the clipboard
#added the logic to remove the enters only in paragraphs
#todo what about the enters after lists ?! requires some backtracking
$text =~s/\r\n([a-z])/ $1/g ; #remove the enters out of it
$text=~s/(—End—|ATTENTION)/\n\n$1\n/g ;
print "the text is \n" ;
print "$text" ;
Win32::Clipboard::Set("$text");
}
1;
__END__
Getting the Current TabItem when the Tab is not selected in WPF
-
[image: Banner]
This is a quick reminder to self on how to retrieve a TabItem from a WPF
TabControl *when the tab is not currently selected* because I ru...
5 days ago
No comments:
Post a Comment
- the first minus - Comments have to be moderated because of the spammers
- the second minus - I am very lazy at moderating comments ... hardly find time ...
- the third minus - Short links are no good for security ...
- The REAL PLUS : Any critic and positive feedback is better than none, so your comments will be published sooner or later !!!!