|Home | Tutorial | Classes | Functions | QSA Workbench | Language | Qt API | QSA Articles Qt Script for Applications

[Prev: Size] [Home] [Next: String]

RegExp

A RegExp is a regular expression matcher for strings.

Regular expressions can be created either by using the /expression/ syntax or by using the RegExp constructor as shown below. Note that when using the RegExp constructor, a string is passed, and all backslashes must be escaped using an extra backslash, i.e. \d. Below are two ways to create regular expressions that matches a pattern of two digits followed by a colon and then another two digits, for example, 17:42.

    var directRegex = /(\d\d):(\d\d)/
    var indirectRegex = new RegExp( "(\\d\\d):(\\d\\d)" );
RegExp Properties
RegExp Functions

[Prev: Size] [Home] [Next: String]


Copyright © 2001-2004 TrolltechTrademarks
QSA version 1.1.0