I'm trying to parse RichText to XML. I want to be able to capture everything between the '/par' tag in the RTF but not include the tag itself. So far all I have is this, '.*?\\par' but it leaves '\par' at the end of it. Any suggestions? (1 Reply)
How can i create a regular expression which can detect a new line charcter followed by a special character say * and replace these both by a string of zero length?
Eg:
Input File san.txt
hello
hi ... (6 Replies)
I have a flat file with the following drug names
Nutropin AQ 20mg PEN Cart 2ml
Norditropin Cart 15mg/1.5ml
I have to extract digits that are before mg i.e 20 and 15 ; how to do this using regular expressions
Thanks
ram (1 Reply)
#!/usr/bin/perl
$word = "one last challenge";
if ( $word =~ /^(\w+).*\s(\w+)$/ )
{
print "$1";
print "\n";
print "$2";
}
The output shows that "$1" is with result one and "$2" is with result challenge. I am confused about how this pattern match expression works step by step. I... (8 Replies)
what elements does " /^/ " match?
I did the test which indicates that it matches single lowercase character like 'a','b' etc. and '1','2' etc.
But I really confused with that. Because, "/^abc/" matches strings like "abcedf" or "abcddddee".
So, what does caret ^ really mean?
Any response... (2 Replies)
I have a file that I'm trying to find all the cases of phone number extensions and deleting them. So input file looks like:
abc
x93825
def
13234
x52673
hello
output looks like:
abc
def
13234
hello
Basically delete lines that have 5 numbers following "x". I tried: x\(4) but it... (7 Replies)
I am new to shell scripts.Can u please help me on this req.
test_user = "Arun"
if
echo "test_user is a word"
else
echo "test_user is not a word" (1 Reply)
Hi
Ilove unix and alwyas trying to to learn unix,but i am weak in using regular expressions.can you please give me a littel brief discription that how can i understand them and how to use .your response could lead a great hand in my unix love. (1 Reply)
Discussion started by: manoj attri
1 Replies
LEARN ABOUT MOJAVE
tk_ungrab
Tk_Grab(3) Tk Library Procedures Tk_Grab(3)__________________________________________________________________________________________________________________________________________________NAME
Tk_Grab, Tk_Ungrab - manipulate grab state in an application
SYNOPSIS
#include <tk.h>
int
Tk_Grab(interp, tkwin, grabGlobal)
void
Tk_Ungrab(tkwin)
ARGUMENTS
Tcl_Interp *interp (in) Interpreter to use for error reporting
Tk_Window tkwin (in) Window on whose behalf the pointer is to be grabbed or released
int grabGlobal (in) Boolean indicating whether the grab is global or application local
_________________________________________________________________DESCRIPTION
These functions are used to set or release a global or application local grab. When a grab is set on a particular window in a Tk applica-
tion, mouse and keyboard events can only be received by that window and its descendants. Mouse and keyboard events for windows outside the
tree rooted at tkwin will be redirected to tkwin. If the grab is global, then all mouse and keyboard events for windows outside the tree
rooted at tkwin (even those intended for windows in other applications) will be redirected to tkwin. If the grab is application local,
only mouse and keyboard events intended for a windows within the same application (but outside the tree rooted at tkwin) will be redi-
rected.
Tk_Grab sets a grab on a particular window. Tkwin specifies the window on whose behalf the pointer is to be grabbed. GrabGlobal indicates
whether the grab should be global or application local; if it is non-zero, it means the grab should be global. Normally, Tk_Grab returns
TCL_OK; if an error occurs and the grab cannot be set, TCL_ERROR is returned and an error message is left if interp's result. Once this
call completes successfully, no window outside the tree rooted at tkwin will receive pointer- or keyboard-related events until the next
call to Tk_Ungrab. If a previous grab was in effect within the application, then it is replaced with a new one.
Tcl_Ungrab releases a grab on the mouse pointer and keyboard, if there is one set on the window given by tkwin. Once a grab is released,
pointer and keyboard events will start being delivered to other windows again.
KEYWORDS
grab, window
TkTk_Grab(3)