Help, How to use GLib's Lexical Scanner??
- From: SolarSea <solarsea gmail com>
- To: gtk-app-devel-list gnome org
- Subject: Help, How to use GLib's Lexical Scanner??
- Date: Wed, 5 Jul 2006 15:24:13 +0800
Hi,
My question is, there is a file, I want to get some lines from it.
Before these lines, there are some multi line comments, which include the
key words I need to search in the file.
For example, the content of the file may like below:
.............................
/*************************************************************
* progress-bar
*************************************************************/
(
some statements
..............
)
................................
I need to search the string "* progress-bar" in the file, get the line
number of it, then get the statements between '(' and ')'. One method is to
use Lex, I find the GLib provide a Lexical Scanner, but I don't know how to
use it, can anybody give me an example of how to implement the function I
have mentioned? Thanks.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]