示例#1
0
/*
	static
*/
void VValueBag::GetKeysFromPath( const VString& inPath, StKeyPath& outKeys)
{
	VFromUnicodeConverter_UTF8 converter;

	char buffer[256];
	VIndex charsConsumed;
	VSize bytesProduced;
	const UniChar *begin = inPath.GetCPointer();
	const UniChar *end = begin + inPath.GetLength();
	for( const UniChar *pos = begin ; pos != end ; ++pos)
	{
		if (*pos == '/')
		{
			bool ok = converter.Convert( begin, (VIndex) (pos - begin), &charsConsumed, buffer, sizeof( buffer), &bytesProduced);
			if (ok)
			{
				outKeys.push_back( StKey( buffer, bytesProduced));
			}
			begin = pos + 1;
		}
	}
	if (begin != end)
	{
		bool ok = converter.Convert( begin, (VIndex) (end - begin), &charsConsumed, buffer, sizeof( buffer), &bytesProduced);
		if (ok)
		{
			outKeys.push_back( StKey( buffer, bytesProduced));
		}
	}
}
示例#2
0
void VValueBag::GetKeysFromUTF8PathNoCopy( const char *inUTF8Path, StKeyPath& outKeys)
{
	const char *begin = inUTF8Path;
	const char *end = begin + ::strlen( inUTF8Path);
	for( const char *pos = begin ; pos != end ; ++pos)
	{
		if (*pos == '/')
		{
			outKeys.push_back( StKey( begin, pos - begin, true));
			begin = pos + 1;
		}
	}
	if (begin != end)
		outKeys.push_back( StKey( begin, end - begin, true));
}
示例#3
0
extern struct PAP	vpapGraySelCur;
#endif

#ifdef MAC
extern int		vftcHelvetica;
#endif

#ifdef JR
extern int              vfJRProps;
#endif /* JR */


/* standard style names */
csconst char rgstStd[][] =
{
	StKey("Normal",NormalFETCH1C),
#ifdef WIN
			StKey("Normal Indent",NormalIndent),
#endif
			StKey("heading 1",Head1),
			StKey("heading 2",Head2),
			StKey("heading 3",Head3),
			StKey("heading 4",Head4),
			StKey("heading 5",Head5),
			StKey("heading 6",Head6),
			StKey("heading 7",Head7),
			StKey("heading 8",Head8),
			StKey("heading 9",Head9),
			StKey("footnote text",FnText),
			StKey("footnote reference",FnRef),
			StKey("header",Header),