You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by ja...@apache.org on 2013/02/23 11:57:01 UTC
svn commit: r1449293 - in /openoffice/branches/l10n/main:
editeng/source/items/ extensions/source/propctrlr/ l10ntools/source/
Author: jani
Date: Sat Feb 23 10:57:00 2013
New Revision: 1449293
URL: http://svn.apache.org/r1449293
Log:
removed x-comment, and updated .src to accept multiline text
Modified:
openoffice/branches/l10n/main/editeng/source/items/svxitems.src
openoffice/branches/l10n/main/extensions/source/propctrlr/formlinkdialog.src
openoffice/branches/l10n/main/extensions/source/propctrlr/formres.src
openoffice/branches/l10n/main/l10ntools/source/gConSrc.hxx
openoffice/branches/l10n/main/l10ntools/source/gConSrcWrap.cxx
openoffice/branches/l10n/main/l10ntools/source/gConSrclex.l
Modified: openoffice/branches/l10n/main/editeng/source/items/svxitems.src
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/editeng/source/items/svxitems.src?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/editeng/source/items/svxitems.src (original)
+++ openoffice/branches/l10n/main/editeng/source/items/svxitems.src Sat Feb 23 10:57:00 2013
@@ -825,7 +825,6 @@ String RID_SVXITEMS_ULSPACE_LOWER
String RID_SVXITEMS_LINES
{
Text [ en-US ] = "%1 Lines" ;
- Text [ x-comment ] = "pb: %1 == will be replaced by the number of lines";
};
String RID_SVXITEMS_WIDOWS_COMPLETE
{
Modified: openoffice/branches/l10n/main/extensions/source/propctrlr/formlinkdialog.src
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/extensions/source/propctrlr/formlinkdialog.src?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/extensions/source/propctrlr/formlinkdialog.src (original)
+++ openoffice/branches/l10n/main/extensions/source/propctrlr/formlinkdialog.src Sat Feb 23 10:57:00 2013
@@ -153,6 +153,5 @@ ModalDialog RID_DLG_FORMLINKS
String STR_ERROR_RETRIEVING_COLUMNS
{
Text [ en-US ] = "The columns of '#' could not be retrieved.";
- Text [ x-comment ] ="# will be replace with a name.";
};
};
Modified: openoffice/branches/l10n/main/extensions/source/propctrlr/formres.src
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/extensions/source/propctrlr/formres.src?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/extensions/source/propctrlr/formres.src (original)
+++ openoffice/branches/l10n/main/extensions/source/propctrlr/formres.src Sat Feb 23 10:57:00 2013
@@ -1492,25 +1492,21 @@ Resource RID_RSC_ENUM_SHEET_ANCHOR_TYPE
String RID_STR_FONTSTYLE_REGULAR
{
Text [ en-US ] = "Regular";
- Text [ x-comment ] = "That's the 'Regular' as used for a font style (as opposed to 'italic' and 'bold'), so please use a consistent translation.";
};
String RID_STR_FONTSTYLE_BOLD_ITALIC
{
Text [ en-US ] = "Bold Italic";
- Text [ x-comment ] = "That's the 'Bold Italic' as used for a font style, so please use a consistent translation.";
};
String RID_STR_FONTSTYLE_ITALIC
{
Text [ en-US ] = "Italic";
- Text [ x-comment ] = "That's the 'Italic' as used for a font style, so please use a consistent translation.";
};
String RID_STR_FONTSTYLE_BOLD
{
Text [ en-US ] = "Bold";
- Text [ x-comment ] = "That's the 'Bold' as used for a font style, so please use a consistent translation.";
};
String RID_STR_FONT_DEFAULT
Modified: openoffice/branches/l10n/main/l10ntools/source/gConSrc.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/l10ntools/source/gConSrc.hxx?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/l10ntools/source/gConSrc.hxx (original)
+++ openoffice/branches/l10n/main/l10ntools/source/gConSrc.hxx Sat Feb 23 10:57:00 2013
@@ -35,10 +35,12 @@
class convert_src : public convert_gen_impl
{
public:
+ bool mbExpectValue;
+
convert_src(l10nMem& crMemory);
~convert_src();
- void setValue (char *syyText);
+ void setValue (char *syyText, char *sbuildValue);
void setLang (char *syyText, bool bEnUs);
void setId (char *syyText, bool bIde);
void setText (char *syyText);
Modified: openoffice/branches/l10n/main/l10ntools/source/gConSrcWrap.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/l10ntools/source/gConSrcWrap.cxx?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/l10ntools/source/gConSrcWrap.cxx (original)
+++ openoffice/branches/l10n/main/l10ntools/source/gConSrcWrap.cxx Sat Feb 23 10:57:00 2013
@@ -41,6 +41,7 @@ convert_src::convert_src(l10nMem& crMemo
mbExpectName(false),
mbExpectMacro(false),
mbExpectStringList(false),
+ mbExpectValue(false),
mbAutoPush(false),
mbValuePresent(false)
{}
@@ -68,7 +69,7 @@ void convert_src::execute()
/********************** I M P L E M E N T A T I O N **********************/
-void convert_src::setValue(char *syyText)
+void convert_src::setValue(char *syyText, char *sbuildValue)
{
if (mbExpectStringList)
{
@@ -83,8 +84,10 @@ void convert_src::setValue(char *syyText
mcStack.push_back(msName);
}
- msValue = copySource(syyText, false);
+ copySource(syyText);
+ msValue = sbuildValue;
mbValuePresent = true;
+ mbExpectValue = false;
}
@@ -95,7 +98,7 @@ void convert_src::setLang(char *syyText,
std::string useText = copySource(syyText) + " is no en-US language";
mbEnUs = bEnUs;
- if (!bEnUs)
+ if (!bEnUs && mbExpectValue)
showError((char *)useText.c_str());
}
@@ -114,7 +117,8 @@ void convert_src::setId(char *syyText, b
/********************** I M P L E M E N T A T I O N **********************/
void convert_src::setText(char *syyText)
{
- msTextName = copySource(syyText);
+ msTextName = copySource(syyText);
+ mbExpectValue = true;
}
@@ -176,6 +180,7 @@ void convert_src::setStringList(char *sy
{
msSaveTextName = msTextName = copySource(syyText);
mbExpectStringList = true;
+
miListCount = 0;
}
@@ -251,7 +256,8 @@ void convert_src::setListItem(char *syyT
if (bIsStart)
{
msTextName = msSaveTextName;
- mbExpectName = true;
+ mbExpectValue =
+ mbExpectName = true;
msName.clear();
}
else
Modified: openoffice/branches/l10n/main/l10ntools/source/gConSrclex.l
URL: http://svn.apache.org/viewvc/openoffice/branches/l10n/main/l10ntools/source/gConSrclex.l?rev=1449293&r1=1449292&r2=1449293&view=diff
==============================================================================
--- openoffice/branches/l10n/main/l10ntools/source/gConSrclex.l (original)
+++ openoffice/branches/l10n/main/l10ntools/source/gConSrclex.l Sat Feb 23 10:57:00 2013
@@ -92,13 +92,27 @@ KEYID [a-zA-Z0-9_-]+
"\"" {
- int i = 0;
- for (; (yytext[++i] = yyinput()) != '\"';)
- if (yytext[i] == '\\')
- yytext[++i] = yyinput();
- yytext[i] = '\0';
+ char buildValue[8000];
+ int j, i;
- LOCptr->setValue(&yytext[1]);
+ // loop across multiple "..." and combine them, while keeping the source
+ buildValue[0] = yytext[0];
+ for (j = i = 0; yytext[i] != ';' ;)
+ {
+ // build current "..."
+ for (; (buildValue[++j] = yytext[++i] = yyinput()) != '\"';)
+ if (yytext[i] == '\\')
+ buildValue[++j] = yytext[++i] = yyinput();
+ --j;
+ // Look for termination or continuation
+ if (LOCptr->mbExpectValue)
+ for (; (yytext[++i] = yyinput()) != ';' && yytext[i] != '\"';) ;
+ else
+ break;
+ }
+ yytext[++i] =
+ buildValue[j+1] = '\0';
+ LOCptr->setValue(yytext, &buildValue[1]);
}