[cc'ed in order to avoid another "does not turn up... yet" lag] On Tue, 28 May 2002 10:50:41 +0100, Alan Fry wrote:
>In the first place you have to use $` to get the starting point of >the 'info-block', which is not very nice. Wow, hold it. Didn't you read all of my message? (;-) I did point towards the @- array, didn't I, which contains the offset of the start for all submatches, with $-[0] pointing towards the start of the whole match? Likewise, @+ contains the offsets of the end of the submatches. >The third difficulty is avoiding a false match >(of the kind Axel mentions). In the ordinary run of events one would >match to /^14 0 obj/. But here you have to be careful because the PDF >file can have any of the three line-endings. I think a regex of the >kind /\012|\01514 0 obj/ would probably be water-tight, but I haven't >tried it. /(?<=[\n\r])14 0 obj/ will likely do. -- Bart.