1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
24 #include "gL10nMem.hxx"
25 #include "gConvXcu.hxx"
27 #define LOCptr ((convert_xcu *)convert_gen::mcImpl)
29 #define YY_INPUT(buf,result,max_size) LOCptr->lexRead(buf, &result, max_size)
30 #define YY_NO_UNISTD_H 1
31 #define yytext_ptr xcutext_ptr
32 #define yy_flex_strncpy convert_gen::lexStrncpy
37 %option prefix="xcu" 8bit noyywrap never-interactive
44 NAME .*"oor:name="\"[^\"]+\"{SPACE}
53 LOCptr->copySource(yytext, false);
58 "<oor:component-data"{NAME} {
61 LOCptr->pushKey(yytext);
68 LOCptr->pushKey(yytext);
73 "</oor:component-data" |
76 LOCptr->popKey(yytext);
80 "<value xml:lang="\"[^\"]+\"[^>]*">" {
81 LOCptr->startCollectData(yytext);
87 LOCptr->stopCollectData(yytext);
97 LOCptr->copySpecial(yytext);
102 ({SPACE}\n{SPACE})+ {
103 LOCptr->copyNL(yytext);
109 LOCptr->copySource(yytext, LOCptr->mbNoCollectingData);
111 // Just to please compiler.
122 void xcu_dummyJustForCompiler()
125 // yy_flex_strlen(txt);