Question: Question 4 Write an application that uses regular expressions to check for telephone numbers and email addresses in a text file provided by a user.
Question
Write an application that uses regular expressions to check for telephone numbers and email addresses in a text file provided by a user. The following functionality should be included.
The user should be able to select the file to check using a standard file open dialog box.
The file should be displayed in the GUI.
The telephone numbers and email addresses should be highlightedemphasized in some way in the text.
An email address can be identified by a single @ symbol in the address; telephone numbers could be from any of the following formats:
You may assume that the email addresses and telephone numbers are free standing, that is they do not have brackets or any other character around them.
See an example below.
HINT: Consider using the QTextDocument, and QTextCursor classes.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
