resyncing to master

This commit is contained in:
Bjoern Michaelsen 2011-07-21 18:56:16 +02:00
commit a233dac065
662 changed files with 10649 additions and 20336 deletions

View File

@ -67,6 +67,11 @@ typedef boost::shared_ptr< const std::vector<Color> > PaletteMemorySharedVecto
struct ImplBitmapDevice;
class BitmapDeviceDamageTracker {
public:
virtual void damaged (const basegfx::B2IRange& rDamageRect) = 0;
};
/** Definition of BitmapDevice interface
Use the createBitmapDevice() factory method to create instances.
@ -115,6 +120,8 @@ public:
*/
RawMemorySharedArray getBuffer() const;
BitmapDeviceDamageTracker *getDamageTracker() const;
/** Get pointer to palette
The returned pointer is const on purpose, since the
@ -548,7 +555,8 @@ protected:
sal_Int32 nScanlineStride,
sal_uInt8* pFirstScanline,
const RawMemorySharedArray& rMem,
const PaletteMemorySharedVector& rPalette );
const PaletteMemorySharedVector& rPalette,
BitmapDeviceDamageTracker* pDamage = NULL );
virtual ~BitmapDevice();
@ -648,7 +656,8 @@ private:
*/
BASEBMP_DLLPUBLIC BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize,
bool bTopDown,
sal_Int32 nScanlineFormat );
sal_Int32 nScanlineFormat,
BitmapDeviceDamageTracker* pDamage = NULL );
/** Factory method to create a BitmapDevice for given scanline format
with the given palette

View File

@ -273,6 +273,7 @@ namespace
dest_iterator_type maBegin;
typename accessor_traits::color_lookup maColorLookup;
BitmapDeviceDamageTracker *mpDamage;
to_uint32_functor maToUInt32Converter;
dest_accessor_type maAccessor;
colorblend_accessor_type maColorBlendAccessor;
@ -288,6 +289,7 @@ namespace
raw_maskedxor_accessor_type maRawMaskedXorAccessor;
raw_maskedmask_accessor_type maRawMaskedMaskAccessor;
// -------------------------------------------------------
BitmapRenderer( const basegfx::B2IRange& rBounds,
@ -298,11 +300,14 @@ namespace
raw_accessor_type rawAccessor,
dest_accessor_type accessor,
const RawMemorySharedArray& rMem,
const PaletteMemorySharedVector& rPalette ) :
const PaletteMemorySharedVector& rPalette,
BitmapDeviceDamageTracker* pDamage ) :
BitmapDevice( rBounds, nScanlineFormat,
nScanlineStride, pFirstScanline, rMem, rPalette ),
nScanlineStride, pFirstScanline, rMem, rPalette,
pDamage ),
maBegin( begin ),
maColorLookup(),
mpDamage( pDamage ),
maToUInt32Converter(),
maAccessor( accessor ),
maColorBlendAccessor( accessor ),
@ -320,6 +325,32 @@ namespace
{}
private:
void damaged( const basegfx::B2IRange& rDamageRect ) const
{
if( mpDamage )
mpDamage->damaged( rDamageRect );
}
void damagedPointSize( const basegfx::B2IPoint& rPoint,
const basegfx::B2IRange& rSize ) const
{
if( mpDamage ) {
basegfx::B2IPoint aLower( rPoint.getX() + rSize.getWidth(),
rPoint.getY() + rSize.getHeight() );
damaged( basegfx::B2IRange( rPoint, aLower ) );
}
}
void damagedPixel( const basegfx::B2IPoint& rDamagePoint ) const
{
if( !mpDamage )
return;
basegfx::B2IPoint aEnd( rDamagePoint.getX() + 1,
rDamagePoint.getY() + 1 );
damaged( basegfx::B2IRange( rDamagePoint, aEnd ) );
}
boost::shared_ptr<BitmapRenderer> getCompatibleBitmap( const BitmapDeviceSharedPtr& bmp ) const
{
return boost::dynamic_pointer_cast< BitmapRenderer >( bmp );
@ -373,6 +404,7 @@ namespace
maColorLookup(
maAccessor,
fillColor) );
damaged( rBounds );
}
virtual void setPixel_i( const basegfx::B2IPoint& rPt,
@ -388,6 +420,7 @@ namespace
else
maAccessor.set( pixelColor,
pixel );
damagedPixel(rPt);
}
virtual void setPixel_i( const basegfx::B2IPoint& rPt,
@ -411,6 +444,7 @@ namespace
else
maMaskedAccessor.set( pixelColor,
aIter );
damagedPixel(rPt);
}
virtual Color getPixel_i(const basegfx::B2IPoint& rPt )
@ -443,6 +477,9 @@ namespace
col,
begin,
rawAcc );
// FIXME: perhaps this needs pushing up the stack a bit
// to make more complex polygons more efficient ...
damaged( basegfx::B2IRange( rPt1, rPt2 ) );
}
template< typename Iterator, typename Accessor, typename RawAcc >
@ -593,6 +630,12 @@ namespace
rBounds,
aPoly,
basegfx::FillRule_EVEN_ODD );
if( mpDamage )
{
basegfx::B2DRange const aPolyBounds( basegfx::tools::getRange(aPoly) );
damaged( basegfx::fround( aPolyBounds ) );
}
}
virtual void fillPolyPolygon_i(const basegfx::B2DPolyPolygon& rPoly,
@ -648,6 +691,7 @@ namespace
acc,
rDstRect),
rSrcBitmap.get() == this );
damaged( rDstRect );
}
template< typename Iterator, typename Acc >
@ -666,6 +710,7 @@ namespace
destIterRange(begin,
acc,
rDstRect));
damaged( rDstRect );
}
virtual void drawBitmap_i(const BitmapDeviceSharedPtr& rSrcBitmap,
@ -695,6 +740,7 @@ namespace
maBegin,
maAccessor);
}
damaged( rDstRect );
}
virtual void drawBitmap_i(const BitmapDeviceSharedPtr& rSrcBitmap,
@ -725,6 +771,7 @@ namespace
getMaskedIter(rClip),
maMaskedAccessor);
}
damaged( rDstRect );
}
virtual void drawMaskedColor_i(Color aSrcColor,
@ -773,6 +820,7 @@ namespace
maGenericColorBlendAccessor,
rDstPoint) );
}
damagedPointSize( rDstPoint, rSrcRect );
}
virtual void drawMaskedColor_i(Color aSrcColor,
@ -835,6 +883,7 @@ namespace
maGenericMaskedColorBlendAccessor,
rDstPoint) );
}
damagedPointSize( rDstPoint, rSrcRect );
}
template< typename Iterator, typename Acc >
@ -865,6 +914,7 @@ namespace
FastMask >::type(acc),
rDstRect),
rSrcBitmap.get() == this);
damaged( rDstRect );
}
template< typename Iterator, typename Acc >
@ -898,6 +948,7 @@ namespace
Masks::clipmask_polarity,
NoFastMask >::type(acc),
rDstRect));
damaged( rDstRect );
}
virtual void drawMaskedBitmap_i(const BitmapDeviceSharedPtr& rSrcBitmap,
@ -933,6 +984,7 @@ namespace
maBegin,
maAccessor);
}
damaged( rDstRect );
}
virtual void drawMaskedBitmap_i(const BitmapDeviceSharedPtr& rSrcBitmap,
@ -969,6 +1021,7 @@ namespace
getMaskedIter(rClip),
maMaskedAccessor);
}
damaged( rDstRect );
}
};
} // namespace
@ -981,6 +1034,8 @@ struct ImplBitmapDevice
*/
RawMemorySharedArray mpMem;
BitmapDeviceDamageTracker *mpDamage;
/// Palette memory plus deleter (might be NULL)
PaletteMemorySharedVector mpPalette;
@ -1037,10 +1092,12 @@ BitmapDevice::BitmapDevice( const basegfx::B2IRange& rBounds,
sal_Int32 nScanlineStride,
sal_uInt8* pFirstScanline,
const RawMemorySharedArray& rMem,
const PaletteMemorySharedVector& rPalette ) :
const PaletteMemorySharedVector& rPalette,
BitmapDeviceDamageTracker* pDamage ) :
mpImpl( new ImplBitmapDevice )
{
mpImpl->mpMem = rMem;
mpImpl->mpDamage = pDamage;
mpImpl->mpPalette = rPalette;
mpImpl->maBounds = rBounds;
mpImpl->maLineClipRect = basegfx::B2IRange( rBounds.getMinX(),
@ -1059,7 +1116,6 @@ BitmapDevice::~BitmapDevice()
basegfx::B2IVector BitmapDevice::getSize() const
{
return basegfx::B2IVector(
mpImpl->maBounds.getMaxX() - mpImpl->maBounds.getMinX(),
mpImpl->maBounds.getMaxY() - mpImpl->maBounds.getMinY() );
@ -1091,6 +1147,11 @@ PaletteMemorySharedVector BitmapDevice::getPalette() const
return mpImpl->mpPalette;
}
BitmapDeviceDamageTracker *BitmapDevice::getDamageTracker() const
{
return mpImpl->mpDamage;
}
sal_Int32 BitmapDevice::getPaletteEntryCount() const
{
return mpImpl->mpPalette ? mpImpl->mpPalette->size() : 0;
@ -1641,8 +1702,8 @@ BitmapDeviceSharedPtr createRenderer(
typename FormatTraits::accessor_selector::template wrap_accessor<
typename FormatTraits::raw_accessor_type>::type const& rAccessor,
boost::shared_array< sal_uInt8 > pMem,
const PaletteMemorySharedVector& pPal )
const PaletteMemorySharedVector& pPal,
BitmapDeviceDamageTracker* pDamage )
#else
template< class FormatTraits, class MaskTraits, class Accessor >
@ -1654,7 +1715,8 @@ BitmapDeviceSharedPtr createRenderer(
typename FormatTraits::raw_accessor_type const& rRawAccessor,
Accessor const& rAccessor,
boost::shared_array< sal_uInt8 > pMem,
const PaletteMemorySharedVector& pPal )
const PaletteMemorySharedVector& pPal,
BitmapDeviceDamageTracker* pDamage )
#endif
{
@ -1676,7 +1738,8 @@ BitmapDeviceSharedPtr createRenderer(
rRawAccessor,
rAccessor,
pMem,
pPal ));
pPal,
pDamage ));
}
/// Create standard grey level palette
@ -1707,7 +1770,8 @@ BitmapDeviceSharedPtr createRenderer(
sal_Int32 nScanlineStride,
sal_uInt8* pFirstScanline,
boost::shared_array< sal_uInt8 > pMem,
const PaletteMemorySharedVector& pPal )
const PaletteMemorySharedVector& pPal,
BitmapDeviceDamageTracker* pDamage )
{
return createRenderer<FormatTraits,
MaskTraits>(rBounds,
@ -1719,7 +1783,8 @@ BitmapDeviceSharedPtr createRenderer(
wrap_accessor<
typename FormatTraits::raw_accessor_type>::type(),
pMem,
pPal);
pPal,
pDamage);
}
template< class FormatTraits, class MaskTraits >
@ -1730,7 +1795,8 @@ BitmapDeviceSharedPtr createRenderer(
sal_uInt8* pFirstScanline,
boost::shared_array< sal_uInt8 > pMem,
PaletteMemorySharedVector pPal,
int nBitsPerPixel )
int nBitsPerPixel,
BitmapDeviceDamageTracker* pDamage )
{
pPal = createStandardPalette(pPal,
1UL << nBitsPerPixel);
@ -1748,7 +1814,8 @@ BitmapDeviceSharedPtr createRenderer(
&pPal->at(0),
pPal->size()),
pMem,
pPal);
pPal,
pDamage);
}
//----------------------------------------------------------------------------------
@ -1784,7 +1851,8 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
sal_Int32 nScanlineFormat,
boost::shared_array< sal_uInt8 > pMem,
PaletteMemorySharedVector pPal,
const basegfx::B2IRange* pSubset )
const basegfx::B2IRange* pSubset,
BitmapDeviceDamageTracker* pDamage )
{
if( nScanlineFormat <= Format::NONE ||
nScanlineFormat > Format::MAX )
@ -1852,24 +1920,24 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::ONE_BIT_MSB_GREY:
return createRenderer<PixelFormatTraits_GREY1_MSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::ONE_BIT_LSB_GREY:
return createRenderer<PixelFormatTraits_GREY1_LSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::ONE_BIT_MSB_PAL:
return createRenderer<PixelFormatTraits_PAL1_MSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal,
bitsPerPixel[nScanlineFormat] );
bitsPerPixel[nScanlineFormat], pDamage );
case Format::ONE_BIT_LSB_PAL:
return createRenderer<PixelFormatTraits_PAL1_LSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal,
bitsPerPixel[nScanlineFormat] );
bitsPerPixel[nScanlineFormat], pDamage );
// ----------------------------------------------------------------------
@ -1878,24 +1946,24 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::FOUR_BIT_MSB_GREY:
return createRenderer<PixelFormatTraits_GREY4_MSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::FOUR_BIT_LSB_GREY:
return createRenderer<PixelFormatTraits_GREY4_LSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::FOUR_BIT_MSB_PAL:
return createRenderer<PixelFormatTraits_PAL4_MSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal,
bitsPerPixel[nScanlineFormat] );
bitsPerPixel[nScanlineFormat], pDamage );
case Format::FOUR_BIT_LSB_PAL:
return createRenderer<PixelFormatTraits_PAL4_LSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal,
bitsPerPixel[nScanlineFormat] );
bitsPerPixel[nScanlineFormat], pDamage );
// ----------------------------------------------------------------------
@ -1904,13 +1972,13 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::EIGHT_BIT_GREY:
return createRenderer<PixelFormatTraits_GREY8,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::EIGHT_BIT_PAL:
return createRenderer<PixelFormatTraits_PAL8,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal,
bitsPerPixel[nScanlineFormat] );
bitsPerPixel[nScanlineFormat], pDamage );
// ----------------------------------------------------------------------
@ -1919,12 +1987,12 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::SIXTEEN_BIT_LSB_TC_MASK:
return createRenderer<PixelFormatTraits_RGB16_565_LSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::SIXTEEN_BIT_MSB_TC_MASK:
return createRenderer<PixelFormatTraits_RGB16_565_MSB,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
// ----------------------------------------------------------------------
@ -1932,7 +2000,7 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::TWENTYFOUR_BIT_TC_MASK:
return createRenderer<PixelFormatTraits_BGR24,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
// ----------------------------------------------------------------------
@ -1941,12 +2009,12 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
case Format::THIRTYTWO_BIT_TC_MASK:
return createRenderer<PixelFormatTraits_RGB32_888,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
case Format::THIRTYTWO_BIT_TC_MASK_ARGB:
return createRenderer<PixelFormatTraits_BGR32_888,StdMasks>(
aBounds, nScanlineFormat, nScanlineStride,
pFirstScanline, pMem, pPal );
pFirstScanline, pMem, pPal, pDamage );
}
// TODO(F3): other formats not yet implemented
@ -1957,14 +2025,16 @@ BitmapDeviceSharedPtr createBitmapDeviceImpl( const basegfx::B2IVector& r
BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize,
bool bTopDown,
sal_Int32 nScanlineFormat )
sal_Int32 nScanlineFormat,
BitmapDeviceDamageTracker* pDamage )
{
return createBitmapDeviceImpl( rSize,
bTopDown,
nScanlineFormat,
boost::shared_array< sal_uInt8 >(),
PaletteMemorySharedVector(),
NULL );
NULL,
pDamage );
}
BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize,
@ -1977,6 +2047,7 @@ BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize
nScanlineFormat,
boost::shared_array< sal_uInt8 >(),
rPalette,
NULL,
NULL );
}
@ -1991,6 +2062,7 @@ BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize
nScanlineFormat,
rMem,
rPalette,
NULL,
NULL );
}
@ -2002,7 +2074,8 @@ BitmapDeviceSharedPtr subsetBitmapDevice( const BitmapDeviceSharedPtr& rProt
rProto->getScanlineFormat(),
rProto->getBuffer(),
rProto->getPalette(),
&rSubset );
&rSubset,
rProto->getDamageTracker() );
}
BitmapDeviceSharedPtr cloneBitmapDevice( const basegfx::B2IVector& rSize,
@ -2013,7 +2086,8 @@ BitmapDeviceSharedPtr cloneBitmapDevice( const basegfx::B2IVector& rSize,
rProto->getScanlineFormat(),
boost::shared_array< sal_uInt8 >(),
rProto->getPalette(),
NULL );
NULL,
rProto->getDamageTracker() );
}
//----------------------------------------------------------------------------------

View File

@ -53,9 +53,6 @@ namespace basegfx
B3DHomMatrix(const B3DHomMatrix& rMat);
~B3DHomMatrix();
/// unshare this matrix with all internally shared instances
void makeUnique();
double get(sal_uInt16 nRow, sal_uInt16 nColumn) const;
void set(sal_uInt16 nRow, sal_uInt16 nColumn, double fValue);
@ -67,20 +64,12 @@ namespace basegfx
/// Reset to the identity matrix
void identity();
bool isInvertible() const;
/// Invert the matrix (if possible)
bool invert();
bool isNormalized() const;
/// Normalize (i.e. force w=1) the matrix
void normalize();
/// Calc the matrix determinant
double determinant() const;
/// Calc the matrix trace
double trace() const;
/// Transpose the matrix
void transpose();
@ -95,8 +84,6 @@ namespace basegfx
// Shearing-Matrices
void shearXY(double fSx, double fSy);
void shearYZ(double fSy, double fSz);
void shearXZ(double fSx, double fSz);
// Projection matrices, used for converting between eye and
// clip coordinates

View File

@ -1,409 +0,0 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
#ifndef _BGFX_POINT_B3DHOMPOINT_HXX
#define _BGFX_POINT_B3DHOMPOINT_HXX
#include <basegfx/point/b3dpoint.hxx>
#include <basegfx/basegfxdllapi.h>
namespace basegfx
{
/** Basic homogen Point class with three double values and one homogen factor
This class provides access to homogen coordinates in 3D.
For this purpose all the operators which need to do specific
action due to their homogenity are implemented here.
The only caveat are member methods which are declared as const
but do change the content. These are documented for that reason.
The class is designed to provide homogenous coordinates without
direct access to the homogen part (mfW). This is also the reason
for leaving out the [] operators which return references to members.
@see B3DTuple
*/
class BASEGFX_DLLPUBLIC B3DHomPoint
{
protected:
/// This member contains the coordinate part of the point
::basegfx::B3DTuple maTuple;
/// This Member holds the homogenous part of the point
double mfW;
/** Test if this homogen point does have a homogenous part
@return Returns true if this point has no homogenous part
*/
bool implIsHomogenized() const
{
const double fOne(1.0);
return ::basegfx::fTools::equal(mfW, fOne);
}
/** Remove homogenous part of this Point
This method does necessary calculations to remove
the evtl. homogenous part of this Point. This may
change all members.
*/
void implHomogenize();
/** Test and on demand remove homogenous part
This method tests if this Point does have a homogenous part
and then evtl. takes actions to remove that part.
@attention Even when this method is const it may change all
members of this instance. This is due to the fact that changing
the homogenous part of a homogenous point does from a mathematical
point of view not change the point at all.
*/
void implTestAndHomogenize() const
{
if(!implIsHomogenized())
((B3DHomPoint*)this)->implHomogenize();
}
public:
/** Create a homogen point
The point is initialized to (0.0, 0.0, 0.0)
*/
B3DHomPoint()
: maTuple(),
mfW(1.0)
{}
/** Create a homogen point
@param fX
This parameter is used to initialize the X-coordinate
of the Point. The homogenous part is initialized to 1.0.
@param fY
This parameter is used to initialize the Y-coordinate
of the Point. The homogenous part is initialized to 1.0.
@param fZ
This parameter is used to initialize the Z-coordinate
of the Point. The homogenous part is initialized to 1.0.
*/
B3DHomPoint(double fX, double fY, double fZ)
: maTuple(fX, fY, fZ),
mfW(1.0)
{}
/** Create a copy of a 3D Point
@param rVec
The 3D point which will be copied. The homogenous part
is initialized to 1.0.
*/
B3DHomPoint(const B3DPoint& rVec)
: maTuple(rVec),
mfW(1.0)
{}
/** Create a copy of a homogen point
@param rVec
The homogen point which will be copied. The homogenous part
is copied, too.
*/
B3DHomPoint(const B3DHomPoint& rVec)
: maTuple(rVec.maTuple.getX(), rVec.maTuple.getY(), rVec.maTuple.getZ()),
mfW(rVec.mfW)
{}
~B3DHomPoint()
{}
/** get a 3D point from this homogenous point
This method normalizes this homogen point if necessary and
returns the corresponding 3D point for this homogen point.
@attention Even when this method is const it may change all
members of this instance.
*/
B3DPoint getB3DPoint() const
{
implTestAndHomogenize();
return B3DPoint(maTuple.getX(), maTuple.getY(), maTuple.getZ());
}
/** get X-coordinate
This method normalizes this homogen point if necessary and
returns the corresponding X-coordinate for this homogen point.
@attention Even when this method is const it may change all
members of this instance.
*/
double getX() const
{
implTestAndHomogenize();
return maTuple.getX();
}
/** get Y-coordinate
This method normalizes this homogen point if necessary and
returns the corresponding Y-coordinate for this homogen point.
@attention Even when this method is const it may change all
members of this instance.
*/
double getY() const
{
implTestAndHomogenize();
return maTuple.getY();
}
/** get Z-coordinate
This method normalizes this homogen point if necessary and
returns the corresponding Z-coordinate for this homogen point.
@attention Even when this method is const it may change all
members of this instance.
*/
double getZ() const
{
implTestAndHomogenize();
return maTuple.getY();
}
/** Set X-coordinate of the homogen point.
This method sets the X-coordinate of the homogen point. If
the point does have a homogenous part this is taken into account.
@param fX
The to-be-set X-coordinate without homogenous part.
*/
void setX(double fX)
{
maTuple.setX(implIsHomogenized() ? fX : fX * mfW );
}
/** Set Y-coordinate of the homogen point.
This method sets the Y-coordinate of the homogen point. If
the point does have a homogenous part this is taken into account.
@param fY
The to-be-set Y-coordinate without homogenous part.
*/
void setY(double fY)
{
maTuple.setY(implIsHomogenized() ? fY : fY * mfW );
}
/** Set Z-coordinate of the homogen point.
This method sets the Z-coordinate of the homogen point. If
the point does have a homogenous part this is taken into account.
@param fZ
The to-be-set Z-coordinate without homogenous part.
*/
void setZ(double fZ)
{
maTuple.setZ(implIsHomogenized() ? fZ : fZ * mfW );
}
// operators
//////////////////////////////////////////////////////////////////////
B3DHomPoint& operator+=( const B3DHomPoint& rPnt )
{
maTuple.setX(getX() * rPnt.mfW + rPnt.getX() * mfW);
maTuple.setY(getY() * rPnt.mfW + rPnt.getY() * mfW);
maTuple.setZ(getZ() * rPnt.mfW + rPnt.getZ() * mfW);
mfW = mfW * rPnt.mfW;
return *this;
}
B3DHomPoint& operator-=( const B3DHomPoint& rPnt )
{
maTuple.setX(getX() * rPnt.mfW - rPnt.getX() * mfW);
maTuple.setY(getY() * rPnt.mfW - rPnt.getY() * mfW);
maTuple.setZ(getZ() * rPnt.mfW - rPnt.getZ() * mfW);
mfW = mfW * rPnt.mfW;
return *this;
}
B3DHomPoint& operator*=(double t)
{
if(!::basegfx::fTools::equalZero(t))
{
mfW /= t;
}
return *this;
}
B3DHomPoint& operator/=(double t)
{
mfW *= t;
return *this;
}
B3DHomPoint& operator-(void)
{
mfW = -mfW;
return *this;
}
bool operator==( const B3DHomPoint& rPnt ) const
{
implTestAndHomogenize();
return (maTuple == rPnt.maTuple);
}
bool operator!=( const B3DHomPoint& rPnt ) const
{
implTestAndHomogenize();
return (maTuple != rPnt.maTuple);
}
B3DHomPoint& operator=( const B3DHomPoint& rPnt )
{
maTuple = rPnt.maTuple;
mfW = rPnt.mfW;
return *this;
}
};
// external operators
//////////////////////////////////////////////////////////////////////////
inline B3DHomPoint minimum(const B3DHomPoint& rVecA, const B3DHomPoint& rVecB)
{
B3DHomPoint aMin(
(rVecB.getX() < rVecA.getX()) ? rVecB.getX() : rVecA.getX(),
(rVecB.getY() < rVecA.getY()) ? rVecB.getY() : rVecA.getY(),
(rVecB.getZ() < rVecA.getZ()) ? rVecB.getZ() : rVecA.getZ());
return aMin;
}
inline B3DHomPoint maximum(const B3DHomPoint& rVecA, const B3DHomPoint& rVecB)
{
B3DHomPoint aMax(
(rVecB.getX() > rVecA.getX()) ? rVecB.getX() : rVecA.getX(),
(rVecB.getY() > rVecA.getY()) ? rVecB.getY() : rVecA.getY(),
(rVecB.getZ() > rVecA.getZ()) ? rVecB.getZ() : rVecA.getZ());
return aMax;
}
inline B3DHomPoint absolute(const B3DHomPoint& rVec)
{
B3DHomPoint aAbs(
(0.0 > rVec.getX()) ? -rVec.getX() : rVec.getX(),
(0.0 > rVec.getY()) ? -rVec.getY() : rVec.getY(),
(0.0 > rVec.getZ()) ? -rVec.getZ() : rVec.getZ());
return aAbs;
}
inline B3DHomPoint interpolate(B3DHomPoint& rOld1, B3DHomPoint& rOld2, double t)
{
B3DHomPoint aInt(
((rOld2.getX() - rOld1.getX()) * t) + rOld1.getX(),
((rOld2.getY() - rOld1.getY()) * t) + rOld1.getY(),
((rOld2.getZ() - rOld1.getZ()) * t) + rOld1.getZ());
return aInt;
}
inline B3DHomPoint average(B3DHomPoint& rOld1, B3DHomPoint& rOld2)
{
B3DHomPoint aAvg(
(rOld1.getX() + rOld2.getX()) * 0.5,
(rOld1.getY() + rOld2.getY()) * 0.5,
(rOld1.getZ() + rOld2.getZ()) * 0.5);
return aAvg;
}
inline B3DHomPoint average(B3DHomPoint& rOld1, B3DHomPoint& rOld2, B3DHomPoint& rOld3)
{
B3DHomPoint aAvg(
(rOld1.getX() + rOld2.getX() + rOld3.getX()) * (1.0 / 3.0),
(rOld1.getY() + rOld2.getY() + rOld3.getY()) * (1.0 / 3.0),
(rOld1.getZ() + rOld2.getZ() + rOld3.getZ()) * (1.0 / 3.0));
return aAvg;
}
inline B3DHomPoint operator+(const B3DHomPoint& rVecA, const B3DHomPoint& rVecB)
{
B3DHomPoint aSum(rVecA);
aSum += rVecB;
return aSum;
}
inline B3DHomPoint operator-(const B3DHomPoint& rVecA, const B3DHomPoint& rVecB)
{
B3DHomPoint aSub(rVecA);
aSub -= rVecB;
return aSub;
}
inline B3DHomPoint operator*(const B3DHomPoint& rVec, double t)
{
B3DHomPoint aNew(rVec);
aNew *= t;
return aNew;
}
inline B3DHomPoint operator*(double t, const B3DHomPoint& rVec)
{
B3DHomPoint aNew(rVec);
aNew *= t;
return aNew;
}
inline B3DHomPoint operator/(const B3DHomPoint& rVec, double t)
{
B3DHomPoint aNew(rVec);
aNew /= t;
return aNew;
}
inline B3DHomPoint operator/(double t, const B3DHomPoint& rVec)
{
B3DHomPoint aNew(rVec);
aNew /= t;
return aNew;
}
} // end of namespace basegfx
#endif /* _BGFX_POINT_B3DHOMPOINT_HXX */
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View File

@ -0,0 +1,55 @@
/*
* Version: MPL 1.1 / GPLv3+ / LGPLv3+
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License or as specified alternatively below. You may obtain a copy of
* the License at http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Initial Developer of the Original Code is
* Thorsten Behrens <tbehrens@novell.com>
* Portions created by the Initial Developer are Copyright (C) 2011 the
* Initial Developer. All Rights Reserved.
*
* For minor contributions see the git repository.
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 3 or later (the "GPLv3+"), or
* the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
* in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
* instead of those above.
*/
#ifndef INCLUDED_BASEGFX_UNOTOOLS_HXX
#define INCLUDED_BASEGFX_UNOTOOLS_HXX
#include <cppuhelper/basemutex.hxx>
#include <cppuhelper/compbase3.hxx>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/rendering/FillRule.hpp>
#include <com/sun/star/rendering/XLinePolyPolygon2D.hpp>
#include <com/sun/star/rendering/XBezierPolyPolygon2D.hpp>
#include <basegfx/polygon/b2dpolypolygon.hxx>
namespace basegfx
{
class B2DPolyPolygon;
namespace unotools
{
B2DPolyPolygon polyPolygonBezierToB2DPolyPolygon(const ::com::sun::star::drawing::PolyPolygonBezierCoords& rSourcePolyPolygon)
throw( ::com::sun::star::lang::IllegalArgumentException );
void b2DPolyPolygonToPolyPolygonBezier( const B2DPolyPolygon& rPolyPoly,
::com::sun::star::drawing::PolyPolygonBezierCoords& rRetval );
}
}
#endif /* INCLUDED_BASEGFX_UNOTOOLS_HXX */

View File

@ -1,3 +1,3 @@
fx basegfx : o3tl sal offuh cppuhelper cppu CPPUNIT:cppunit NULL
fx basegfx : o3tl sal offapi comphelper cppuhelper cppu CPPUNIT:cppunit NULL
fx basegfx\prj nmake - all fx_prj NULL

View File

@ -0,0 +1 @@
..\inc\basegfx\tools\unotools.hxx %_DEST%\inc\basegfx\tools\unotools.hxx

View File

@ -63,11 +63,6 @@ namespace basegfx
return *this;
}
void B3DHomMatrix::makeUnique()
{
mpImpl.make_unique();
}
double B3DHomMatrix::get(sal_uInt16 nRow, sal_uInt16 nColumn) const
{
return mpImpl->get(nRow, nColumn);
@ -96,11 +91,6 @@ namespace basegfx
mpImpl = IdentityMatrix::get();
}
bool B3DHomMatrix::isInvertible() const
{
return mpImpl->isInvertible();
}
bool B3DHomMatrix::invert()
{
Impl3DHomMatrix aWork(*mpImpl);
@ -119,27 +109,11 @@ namespace basegfx
return false;
}
bool B3DHomMatrix::isNormalized() const
{
return mpImpl->isNormalized();
}
void B3DHomMatrix::normalize()
{
if(!const_cast<const B3DHomMatrix*>(this)->mpImpl->isNormalized())
mpImpl->doNormalize();
}
double B3DHomMatrix::determinant() const
{
return mpImpl->doDeterminant();
}
double B3DHomMatrix::trace() const
{
return mpImpl->doTrace();
}
void B3DHomMatrix::transpose()
{
mpImpl->doTranspose();
@ -290,34 +264,6 @@ namespace basegfx
}
}
void B3DHomMatrix::shearYZ(double fSy, double fSz)
{
// #i76239# do not test againt 1.0, but against 0.0. We are talking about a value not on the diagonal (!)
if(!fTools::equalZero(fSy) || !fTools::equalZero(fSz))
{
Impl3DHomMatrix aShearYZMat;
aShearYZMat.set(1, 0, fSy);
aShearYZMat.set(2, 0, fSz);
mpImpl->doMulMatrix(aShearYZMat);
}
}
void B3DHomMatrix::shearXZ(double fSx, double fSz)
{
// #i76239# do not test againt 1.0, but against 0.0. We are talking about a value not on the diagonal (!)
if(!fTools::equalZero(fSx) || !fTools::equalZero(fSz))
{
Impl3DHomMatrix aShearXZMat;
aShearXZMat.set(0, 1, fSx);
aShearXZMat.set(2, 1, fSz);
mpImpl->doMulMatrix(aShearXZMat);
}
}
void B3DHomMatrix::frustum(double fLeft, double fRight, double fBottom, double fTop, double fNear, double fFar)
{
const double fZero(0.0);

View File

@ -93,21 +93,10 @@ public:
void insert(sal_uInt32 nIndex, const basegfx::B2DPolyPolygon& rPolyPolygon)
{
const sal_uInt32 nCount = rPolyPolygon.count();
if(nCount)
{
// add nCount polygons from rPolyPolygon
maPolygons.reserve(maPolygons.size() + nCount);
PolygonVector::iterator aIndex(maPolygons.begin());
aIndex += nIndex;
for(sal_uInt32 a(0L); a < nCount; a++)
{
aIndex = maPolygons.insert(aIndex, rPolyPolygon.getB2DPolygon(a));
++aIndex;
}
}
// add all polygons from rPolyPolygon
PolygonVector::iterator aIndex(maPolygons.begin());
aIndex += nIndex;
maPolygons.insert(aIndex, rPolyPolygon.begin(), rPolyPolygon.end());
}
void remove(sal_uInt32 nIndex, sal_uInt32 nCount)

View File

@ -787,10 +787,7 @@ namespace basegfx
// (since
// createPolygonFromEllipseSegment()
// normalizes to e.g. cw arc)
const bool bLessThanPi(fmod(fTheta2+2*M_PI-fTheta1,
2*M_PI)<M_PI);
const bool bFlipSegment( (bLargeArcFlag!=0) == bLessThanPi );
if( bFlipSegment )
if( !bSweepFlag )
std::swap(fTheta1,fTheta2);
// finally, create bezier polygon from this
@ -812,7 +809,7 @@ namespace basegfx
// always creates arcs that are
// positively oriented - flip polygon
// if we swapped angles above
if( bFlipSegment )
if( !bSweepFlag )
aSegment.flip();
aCurrPoly.append(aSegment);
}

View File

@ -0,0 +1,264 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2008 by Sun Microsystems, Inc.
*
* Portions Copright 2011 Thorsten Behrens <tbehrens@novell.com>
*
* OpenOffice.org - a multi-platform office productivity suite
*
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version 3
* only, as published by the Free Software Foundation.
*
* OpenOffice.org is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License version 3 for more details
* (a copy is included in the LICENSE file that accompanied this code).
*
* You should have received a copy of the GNU Lesser General Public License
* version 3 along with OpenOffice.org. If not, see
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
************************************************************************/
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_basegfx.hxx"
#include <com/sun/star/drawing/PolyPolygonBezierCoords.hpp>
#include <com/sun/star/drawing/PointSequence.hpp>
#include <com/sun/star/drawing/FlagSequence.hpp>
#include <basegfx/polygon/b2dpolypolygontools.hxx>
#include <basegfx/polygon/b2dpolygontools.hxx>
#include <basegfx/polygon/b2dpolygon.hxx>
#include <basegfx/curve/b2dcubicbezier.hxx>
#include <basegfx/tools/unotools.hxx>
#include <comphelper/sequence.hxx>
using namespace ::com::sun::star;
namespace basegfx
{
namespace unotools
{
B2DPolyPolygon polyPolygonBezierToB2DPolyPolygon(const drawing::PolyPolygonBezierCoords& rSourcePolyPolygon)
throw( lang::IllegalArgumentException )
{
const sal_Int32 nOuterSequenceCount(rSourcePolyPolygon.Coordinates.getLength());
B2DPolyPolygon aNewPolyPolygon;
if(rSourcePolyPolygon.Flags.getLength() != nOuterSequenceCount)
throw lang::IllegalArgumentException();
// get pointers to inner sequence
const drawing::PointSequence* pInnerSequence = rSourcePolyPolygon.Coordinates.getConstArray();
const drawing::FlagSequence* pInnerSequenceFlags = rSourcePolyPolygon.Flags.getConstArray();
for(sal_Int32 a(0); a < nOuterSequenceCount; a++)
{
const sal_Int32 nInnerSequenceCount(pInnerSequence->getLength());
if(pInnerSequenceFlags->getLength() != nInnerSequenceCount)
throw lang::IllegalArgumentException();
// prepare new polygon
basegfx::B2DPolygon aNewPolygon;
const awt::Point* pArray = pInnerSequence->getConstArray();
const drawing::PolygonFlags* pArrayFlags = pInnerSequenceFlags->getConstArray();
// get first point and flag
basegfx::B2DPoint aNewCoordinatePair(pArray->X, pArray->Y); pArray++;
drawing::PolygonFlags ePolyFlag(*pArrayFlags); pArrayFlags++;
basegfx::B2DPoint aControlA;
basegfx::B2DPoint aControlB;
// first point is not allowed to be a control point
if(drawing::PolygonFlags_CONTROL == ePolyFlag)
throw lang::IllegalArgumentException();
// add first point as start point
aNewPolygon.append(aNewCoordinatePair);
for(sal_Int32 b(1); b < nInnerSequenceCount;)
{
// prepare loop
bool bControlA(false);
bool bControlB(false);
// get next point and flag
aNewCoordinatePair = basegfx::B2DPoint(pArray->X, pArray->Y);
ePolyFlag = *pArrayFlags;
pArray++; pArrayFlags++; b++;
if(b < nInnerSequenceCount && drawing::PolygonFlags_CONTROL == ePolyFlag)
{
aControlA = aNewCoordinatePair;
bControlA = true;
// get next point and flag
aNewCoordinatePair = basegfx::B2DPoint(pArray->X, pArray->Y);
ePolyFlag = *pArrayFlags;
pArray++; pArrayFlags++; b++;
}
if(b < nInnerSequenceCount && drawing::PolygonFlags_CONTROL == ePolyFlag)
{
aControlB = aNewCoordinatePair;
bControlB = true;
// get next point and flag
aNewCoordinatePair = basegfx::B2DPoint(pArray->X, pArray->Y);
ePolyFlag = *pArrayFlags;
pArray++; pArrayFlags++; b++;
}
// two or no control points are consumed, another one would be an error.
// It's also an error if only one control point was read
if(drawing::PolygonFlags_CONTROL == ePolyFlag || bControlA != bControlB)
throw lang::IllegalArgumentException();
// the previous writes used the B2DPolyPoygon -> PolyPolygon converter
// which did not create minimal PolyPolygons, but created all control points
// as null vectors (identical points). Because of the former P(CA)(CB)-norm of
// B2DPolygon and it's unused sign of being the zero-vector and CA and CB being
// relative to P, an empty edge was exported as P == CA == CB. Luckily, the new
// export format can be read without errors by the old OOo-versions, so we need only
// to correct here at read and do not need to export a wrong but compatible version
// for the future.
if(bControlA
&& aControlA.equal(aControlB)
&& aControlA.equal(aNewPolygon.getB2DPoint(aNewPolygon.count() - 1)))
{
bControlA = bControlB = false;
}
if(bControlA)
{
// add bezier edge
aNewPolygon.appendBezierSegment(aControlA, aControlB, aNewCoordinatePair);
}
else
{
// add edge
aNewPolygon.append(aNewCoordinatePair);
}
}
// next sequence
pInnerSequence++;
pInnerSequenceFlags++;
// #i72807# API import uses old line start/end-equal definition for closed,
// so we need to correct this to closed state here
basegfx::tools::checkClosed(aNewPolygon);
// add new subpolygon
aNewPolyPolygon.append(aNewPolygon);
}
return aNewPolyPolygon;
}
/////////////////////////////////////////////////////////////////////////////////
void b2DPolyPolygonToPolyPolygonBezier( const basegfx::B2DPolyPolygon& rPolyPoly,
drawing::PolyPolygonBezierCoords& rRetval )
{
rRetval.Coordinates.realloc(rPolyPoly.count());
rRetval.Flags.realloc(rPolyPoly.count());
drawing::PointSequence* pOuterSequence = rRetval.Coordinates.getArray();
drawing::FlagSequence* pOuterFlags = rRetval.Flags.getArray();
for(sal_uInt32 a=0;a<rPolyPoly.count();a++)
{
const B2DPolygon& rPoly = rPolyPoly.getB2DPolygon(a);
sal_uInt32 nCount(rPoly.count());
const bool bClosed(rPoly.isClosed());
// calculate input vertex count
const sal_uInt32 nLoopCount(bClosed ? nCount : (nCount ? nCount - 1L : 0L ));
std::vector<awt::Point> aPoints; aPoints.reserve(nLoopCount);
std::vector<drawing::PolygonFlags> aFlags; aFlags.reserve(nLoopCount);
// prepare insert index and current point
basegfx::B2DCubicBezier aBezier;
aBezier.setStartPoint(rPoly.getB2DPoint(0));
for(sal_uInt32 b(0L); b<nLoopCount; b++)
{
// add current point (always) and remember StartPointIndex for evtl. later corrections
const awt::Point aStartPoint(fround(aBezier.getStartPoint().getX()),
fround(aBezier.getStartPoint().getY()));
const sal_uInt32 nStartPointIndex(aPoints.size());
aPoints.push_back(aStartPoint);
aFlags.push_back(drawing::PolygonFlags_NORMAL);
// prepare next segment
const sal_uInt32 nNextIndex((b + 1) % nCount);
aBezier.setEndPoint(rPoly.getB2DPoint(nNextIndex));
aBezier.setControlPointA(rPoly.getNextControlPoint(b));
aBezier.setControlPointB(rPoly.getPrevControlPoint(nNextIndex));
if(aBezier.isBezier())
{
// if one is used, add always two control points due to the old schema
aPoints.push_back( awt::Point(fround(aBezier.getControlPointA().getX()),
fround(aBezier.getControlPointA().getY())) );
aFlags.push_back(drawing::PolygonFlags_CONTROL);
aPoints.push_back( awt::Point(fround(aBezier.getControlPointB().getX()),
fround(aBezier.getControlPointB().getY())) );
aFlags.push_back(drawing::PolygonFlags_CONTROL);
}
// test continuity with previous control point to set flag value
if(aBezier.getControlPointA() != aBezier.getStartPoint() && (bClosed || b))
{
const basegfx::B2VectorContinuity eCont(rPoly.getContinuityInPoint(b));
if(basegfx::CONTINUITY_C1 == eCont)
{
aFlags[nStartPointIndex] = drawing::PolygonFlags_SMOOTH;
}
else if(basegfx::CONTINUITY_C2 == eCont)
{
aFlags[nStartPointIndex] = drawing::PolygonFlags_SYMMETRIC;
}
}
// prepare next polygon step
aBezier.setStartPoint(aBezier.getEndPoint());
}
if(bClosed)
{
// add first point again as closing point due to old definition
aPoints.push_back( aPoints[0] );
aFlags.push_back(drawing::PolygonFlags_NORMAL);
}
else
{
// add last point as closing point
const basegfx::B2DPoint aClosingPoint(rPoly.getB2DPoint(nCount - 1L));
const awt::Point aEnd(fround(aClosingPoint.getX()),
fround(aClosingPoint.getY()));
aPoints.push_back(aEnd);
aFlags.push_back(drawing::PolygonFlags_NORMAL);
}
*pOuterSequence++ = comphelper::containerToSequence(aPoints);
*pOuterFlags++ = comphelper::containerToSequence(aFlags);
}
}
}
}

View File

@ -67,33 +67,6 @@ public:
}; // class b3dhommatrix
class b3dhompoint : public CppUnit::TestFixture
{
public:
// initialise your test code values here.
void setUp()
{
}
void tearDown()
{
}
// insert your test code here.
void EmptyMethod()
{
}
// Change the following lines only, if you add, remove or rename
// member functions of the current class,
// because these macros are need by auto register mechanism.
CPPUNIT_TEST_SUITE(b3dhompoint);
CPPUNIT_TEST(EmptyMethod);
CPPUNIT_TEST_SUITE_END();
}; // class b3dhompoint
class b3dpoint : public CppUnit::TestFixture
{
public:
@ -207,7 +180,6 @@ public:
// -----------------------------------------------------------------------------
CPPUNIT_TEST_SUITE_REGISTRATION(basegfx3d::b3dhommatrix);
CPPUNIT_TEST_SUITE_REGISTRATION(basegfx3d::b3dhompoint);
CPPUNIT_TEST_SUITE_REGISTRATION(basegfx3d::b3dpoint);
CPPUNIT_TEST_SUITE_REGISTRATION(basegfx3d::b3drange);
CPPUNIT_TEST_SUITE_REGISTRATION(basegfx3d::b3dtuple);

View File

@ -1,3 +1,3 @@
cv canvas : javaunohelper comphelper cppuhelper offuh unoil tools svtools vcl basegfx CAIRO:cairo LIBXSLT:libxslt NULL
cv canvas : javaunohelper comphelper cppuhelper offapi unoil tools svtools vcl basegfx CAIRO:cairo LIBXSLT:libxslt NULL
cv canvas\prj nmake - all cv_prj NULL

View File

@ -0,0 +1 @@
..\%__SRC%\lib\*.a %_DEST%\lib\*.a

View File

@ -128,13 +128,11 @@ namespace cairocanvas
{
if( rColor.getLength() > 3 )
{
const double alpha = rColor[3];
cairo_set_source_rgba( pCairo,
alpha*rColor[0],
alpha*rColor[1],
alpha*rColor[2],
alpha );
rColor[0],
rColor[1],
rColor[2],
rColor[3] );
}
else if( rColor.getLength() == 3 )
cairo_set_source_rgb( pCairo,

View File

@ -29,9 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_canvas.hxx"
#ifdef QUARTZ
#if defined QUARTZ || defined IOS
/************************************************************************
* Mac OS X/Quartz surface backend for OpenOffice.org Cairo Canvas *
* Mac OS X/Quartz and iOS surface backend for OpenOffice.org Cairo Canvas *
************************************************************************/
#include <osl/diagnose.h>
@ -205,13 +205,19 @@ namespace cairo
CGContextRef mrContext = getCGContext();
if (!mrContext) return;
#ifndef IOS
[mpView lockFocus];
#endif
#ifndef IOS
/**
* This code is using same screen update code as in VCL (esp. AquaSalGraphics::UpdateWindow() )
*/
CGContextRef rViewContext = reinterpret_cast<CGContextRef>([[NSGraphicsContext currentContext] graphicsPort]);
#else
// Just guessing for now...
CGContextRef rViewContext = UIGraphicsGetCurrentContext();
#endif
CGImageRef xImage = CGBitmapContextCreateImage(mrContext);
CGContextDrawImage(rViewContext,
CGRectMake( 0, 0,
@ -220,8 +226,9 @@ namespace cairo
xImage);
CGImageRelease( xImage );
CGContextFlush( rViewContext );
#ifndef IOS
[mpView unlockFocus];
#endif
}
/**

View File

@ -32,7 +32,13 @@
#include "cairo_cairo.hxx"
#include "premac.h"
#include <TargetConditionals.h>
#if !defined(TARGET_OS_IPHONE) || !TARGET_OS_IPHONE
#include <Cocoa/Cocoa.h>
#else
#include <UIKit/UIKit.h>
#define NSView UIView
#endif
#include <cairo-quartz.h>
#include "postmac.h"

View File

@ -524,8 +524,8 @@ namespace cairocanvas
::cairo::SurfaceSharedPtr SpriteCanvasHelper::getCompositingSurface( const ::basegfx::B2ISize& rNeededSize )
{
if( rNeededSize.getX() < maCompositingSurfaceSize.getX() ||
rNeededSize.getY() < maCompositingSurfaceSize.getY() )
if( rNeededSize.getX() > maCompositingSurfaceSize.getX() ||
rNeededSize.getY() > maCompositingSurfaceSize.getY() )
{
// need to give buffer more size
mpCompositingSurface.reset();

View File

@ -352,7 +352,7 @@ namespace cairocanvas
**/
bool TextLayout::isCairoRenderable(SystemFontData aSysFontData) const
{
#if defined UNX && !defined QUARTZ
#if defined UNX && !defined QUARTZ && !defined IOS
// is font usable?
if (!aSysFontData.nFontId) return false;
#endif
@ -502,9 +502,14 @@ namespace cairocanvas
cairo_font_face_t* font_face = NULL;
#ifdef CAIRO_HAS_QUARTZ_SURFACE
#ifdef QUARTZ
// TODO: use cairo_quartz_font_face_create_for_cgfont(cgFont)
// when CGFont (Mac OS X 10.5 API) is provided by the AQUA VCL backend.
font_face = cairo_quartz_font_face_create_for_atsu_font_id((ATSUFontID) rSysFontData.aATSUFontID);
#else // iOS
font_face = cairo_quartz_font_face_create_for_cgfont( rSysFontData.rFont);
#endif
#elif defined CAIRO_HAS_WIN32_SURFACE
#if (OSL_DEBUG_LEVEL > 1)

View File

@ -527,12 +527,6 @@ const ::cppu::ImplementationEntry s_entries [] = {
extern "C" {
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory(
sal_Char const * pImplName,
lang::XMultiServiceFactory * pServiceManager,

View File

@ -37,7 +37,6 @@ $(eval $(call gb_Library_set_include,comphelper,\
-I$(realpath $(SRCDIR)/comphelper/inc/pch) \
-I$(realpath $(SRCDIR)/comphelper/source/inc) \
$$(INCLUDE) \
-I$(OUTDIR)/inc/offuh \
))
$(eval $(call gb_Library_add_defs,comphelper,\
@ -52,6 +51,11 @@ $(eval $(call gb_Library_add_linked_libs,comphelper,\
$(gb_STDLIBS) \
))
$(eval $(call gb_Library_add_api,comphelper,\
udkapi \
offapi \
))
$(eval $(call gb_Library_add_exception_objects,comphelper,\
comphelper/source/compare/AnyCompareFactory \
comphelper/source/container/IndexedPropertyValuesContainer \

View File

@ -270,103 +270,6 @@ namespace comphelper
) );
}
//==========================================================================
//= helpers
//==========================================================================
//==========================================================================
// declaring a OModule for a component library
#define DECLARE_COMPONENT_MODULE( ModuleClass, ClientClass ) \
/* -------------------------------------------------------------------- */ \
class ModuleClass : public ::comphelper::OModule \
{ \
friend struct ModuleClass##Creator; \
typedef ::comphelper::OModule BaseClass; \
\
public: \
static ModuleClass& getInstance(); \
\
private: \
ModuleClass(); \
}; \
\
/* -------------------------------------------------------------------- */ \
class ClientClass : public ::comphelper::OModuleClient \
{ \
private: \
typedef ::comphelper::OModuleClient BaseClass; \
\
public: \
ClientClass() : BaseClass( ModuleClass::getInstance() ) \
{ \
} \
}; \
\
/* -------------------------------------------------------------------- */ \
template < class TYPE > \
class OAutoRegistration : public ::comphelper::OAutoRegistration< TYPE > \
{ \
private: \
typedef ::comphelper::OAutoRegistration< TYPE > BaseClass; \
\
public: \
OAutoRegistration() : BaseClass( ModuleClass::getInstance() ) \
{ \
} \
}; \
/* -------------------------------------------------------------------- */ \
template < class TYPE > \
class OSingletonRegistration : public ::comphelper::OSingletonRegistration< TYPE > \
{ \
private: \
typedef ::comphelper::OSingletonRegistration< TYPE > BaseClass; \
\
public: \
OSingletonRegistration() : BaseClass( ModuleClass::getInstance() ) \
{ \
} \
};
//==========================================================================
//= implementing a OModule for a component library
#define IMPLEMENT_COMPONENT_MODULE( ModuleClass ) \
struct ModuleClass##Creator \
{ \
ModuleClass m_aModuleClass; \
}; \
namespace \
{ \
class the##ModuleClass##Instance : public rtl::Static<ModuleClass##Creator, the##ModuleClass##Instance> {}; \
} \
\
ModuleClass::ModuleClass() \
:BaseClass() \
{ \
} \
\
ModuleClass& ModuleClass::getInstance() \
{ \
return the##ModuleClass##Instance::get().m_aModuleClass; \
} \
//==========================================================================
//= implementing the API of a component library (component_*)
#define IMPLEMENT_COMPONENT_LIBRARY_API( module_class, initializer_function ) \
extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment( \
const sal_Char **ppEnvTypeName, uno_Environment ** /*ppEnv*/ ) \
{ \
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; \
} \
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( \
const sal_Char* pImplementationName, void* pServiceManager, void* pRegistryKey ) \
{ \
initializer_function(); \
return module_class::getInstance().getComponentFactory( pImplementationName, pServiceManager, pRegistryKey ); \
}
//........................................................................
} // namespace comphelper
//........................................................................

View File

@ -387,12 +387,6 @@ BOOST_PP_REPEAT_FROM_TO(1, COMPHELPER_SERVICEDECL_COMPONENT_HELPER_MAX_ARGS,
#define COMPHELPER_SERVICEDECL_make_exports(varargs_ ) \
extern "C" \
{ \
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment( const sal_Char** ppEnvTypeName, \
uno_Environment** /*ppEnv*/ ) \
{ \
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; \
} \
\
SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( sal_Char const* pImplName, \
::com::sun::star::lang::XMultiServiceFactory* pServiceManager, \
::com::sun::star::registry::XRegistryKey* pRegistryKey ) \

View File

@ -128,14 +128,6 @@ public:
const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >& xStorage )
throw ( ::com::sun::star::uno::Exception );
// The followin methods are related to creation of a storage of specified format
static ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >
GetTemporaryStorageOfFormat(
const ::rtl::OUString& aFormat,
const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xFactory
= ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >() )
throw ( ::com::sun::star::uno::Exception );
static ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >
GetStorageOfFormatFromURL(
const ::rtl::OUString& aFormat,

View File

@ -1,2 +1,2 @@
ph comphelper : cppuhelper ucbhelper offuh salhelper LIBXSLT:libxslt NULL
ph comphelper : cppuhelper ucbhelper offapi salhelper LIBXSLT:libxslt NULL
ch comphelper\prj nmake - all ch_all NULL

View File

@ -35,7 +35,55 @@ namespace comphelper { namespace module
{
//........................................................................
DECLARE_COMPONENT_MODULE( ComphelperModule, ComphelperModuleClient )
class ComphelperModule : public ::comphelper::OModule
{
friend struct ComphelperModuleCreator;
typedef ::comphelper::OModule BaseClass;
public:
static ComphelperModule& getInstance();
private:
ComphelperModule();
};
/* -------------------------------------------------------------------- */
class ComphelperModuleClient : public ::comphelper::OModuleClient
{
private:
typedef ::comphelper::OModuleClient BaseClass;
public:
ComphelperModuleClient() : BaseClass( ComphelperModule::getInstance() )
{
}
};
/* -------------------------------------------------------------------- */
template < class TYPE >
class OAutoRegistration : public ::comphelper::OAutoRegistration< TYPE >
{
private:
typedef ::comphelper::OAutoRegistration< TYPE > BaseClass;
public:
OAutoRegistration() : BaseClass( ComphelperModule::getInstance() )
{
}
};
/* -------------------------------------------------------------------- */
template < class TYPE >
class OSingletonRegistration : public ::comphelper::OSingletonRegistration< TYPE >
{
private:
typedef ::comphelper::OSingletonRegistration< TYPE > BaseClass;
public:
OSingletonRegistration() : BaseClass( ComphelperModule::getInstance() )
{
}
};
//........................................................................
} } // namespace comphelper::module

View File

@ -35,7 +35,24 @@ namespace comphelper { namespace module
{
//........................................................................
IMPLEMENT_COMPONENT_MODULE( ComphelperModule );
struct ComphelperModuleCreator
{
ComphelperModule m_aComphelperModule;
};
namespace
{
class theComphelperModuleInstance : public rtl::Static<ComphelperModuleCreator, theComphelperModuleInstance> {};
}
ComphelperModule::ComphelperModule()
:BaseClass()
{
}
ComphelperModule& ComphelperModule::getInstance()
{
return theComphelperModuleInstance::get().m_aComphelperModule;
}
//........................................................................
} } // namespace comphelper::module

View File

@ -85,6 +85,11 @@ namespace comphelper { namespace module
} } // namespace comphelper::module
//........................................................................
IMPLEMENT_COMPONENT_LIBRARY_API( ::comphelper::module::ComphelperModule, ::comphelper::module::initializeModule )
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName, void* pServiceManager, void* pRegistryKey )
{
::comphelper::module::initializeModule();
return ::comphelper::module::ComphelperModule::getInstance().getComponentFactory( pImplementationName, pServiceManager, pRegistryKey );
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View File

@ -313,23 +313,6 @@ sal_Int32 OStorageHelper::GetXStorageFormat(
return nResult;
}
// ----------------------------------------------------------------------
uno::Reference< embed::XStorage > OStorageHelper::GetTemporaryStorageOfFormat(
const ::rtl::OUString& aFormat,
const uno::Reference< lang::XMultiServiceFactory >& xFactory )
throw ( uno::Exception )
{
uno::Reference< lang::XMultiServiceFactory > xFactoryToUse = xFactory.is() ? xFactory : ::comphelper::getProcessServiceFactory();
if ( !xFactoryToUse.is() )
throw uno::RuntimeException();
uno::Reference< io::XStream > xTmpStream(
xFactoryToUse->createInstance( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.TempFile" ) ) ),
uno::UNO_QUERY_THROW );
return GetStorageOfFormatFromStream( aFormat, xTmpStream, embed::ElementModes::READWRITE, xFactoryToUse );
}
// ----------------------------------------------------------------------
uno::Reference< embed::XStorage > OStorageHelper::GetStorageOfFormatFromURL(
const ::rtl::OUString& aFormat,

View File

@ -1,2 +1,2 @@
cx cppcanvas : comphelper cppuhelper offuh tools vcl basegfx canvas NULL
cx cppcanvas : comphelper cppuhelper offapi tools vcl basegfx canvas NULL
cx cppcanvas\prj nmake - all cx_prj NULL

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -1,7 +1,6 @@
UDK_3_0_0 {
global:
_ZTI*; _ZTS*; # weak RTTI symbols for C++ exceptions
component_getImplementationEnvironment;
component_getFactory;
local:
*;

View File

@ -1,4 +1,4 @@
dr dtrans : unotools offapi offuh rdbmaker stoc LIBXSLT:libxslt NULL
dr dtrans : unotools offapi DESKTOP:rdbmaker stoc LIBXSLT:libxslt NULL
dr dtrans usr1 - all dr_mkout NULL
dr dtrans\inc nmake - all dr_inc NULL
dr dtrans\source\cnttype nmake - all dr_cnttype dr_generic dr_inc NULL

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -83,23 +83,8 @@ namespace
}
}
//-----------------------------------------------------------------------------------------------------------
// the 3 important functions which will be exported
//-----------------------------------------------------------------------------------------------------------
extern "C"
{
//----------------------------------------------------------------------
// component_getImplementationEnvironment
//----------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//----------------------------------------------------------------------
// component_getFactory
// returns a factory to create XFilePicker-Services

View File

@ -219,8 +219,7 @@ void SAL_CALL ClipboardManager::dispose()
xComponent->removeEventListener(static_cast < XEventListener * > (this));
xComponent->dispose();
}
catch(Exception e)
catch (const Exception&)
{
// exceptions can be safely ignored here.
}

View File

@ -46,14 +46,6 @@ extern "C"
//==================================================================================================
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(const sal_Char ** ppEnvTypeName,
uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//==================================================================================================
SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory(
const sal_Char * pImplName,
void * pServiceManager,

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -465,13 +465,13 @@ int SAL_CALL main( int argc, const char* argv[] )
xClipboardManager->getClipboard( OUString(RTL_CONSTASCII_USTRINGPARAM("generic")) );
TRACE( "FAILED\n" );
}
catch( NoSuchElementException e )
catch (const NoSuchElementException&)
{
TRACE( "passed\n" );
}
}
catch ( Exception aException )
catch (const Exception&)
{
ENSURE( sal_False, "*** ERROR *** exception caught." );
}

View File

@ -36,11 +36,11 @@
#include "WinClipbImpl.hxx"
#include <systools/win32/comtools.hxx>
#include "..\..\inc\DtObjFactory.hxx"
#include "..\dtobj\APNDataObject.hxx"
#include "../../inc/DtObjFactory.hxx"
#include "../dtobj/APNDataObject.hxx"
#include "WinClipboard.hxx"
#include <com/sun/star/datatransfer/clipboard/RenderingCapabilities.hpp>
#include "..\dtobj\XNotifyingDataObject.hxx"
#include "../dtobj/XNotifyingDataObject.hxx"
#if defined _MSC_VER
#pragma warning(push,1)
@ -200,11 +200,11 @@ sal_Int8 SAL_CALL CWinClipbImpl::getRenderingCapabilities( ) throw( RuntimeExce
void SAL_CALL CWinClipbImpl::flushClipboard( ) throw( RuntimeException )
{
// sollte eigentlich hier stehen: ClearableMutexGuard aGuard( m_ClipContentMutex );
// geht aber nicht, da FlushClipboard zurückruft und das DataObject
// freigibt und damit würde es einen Deadlock in onReleaseDataObject geben
// FlushClipboard muß synchron sein, damit das runterfahren ggf. erst weitergeht,
// geht aber nicht, da FlushClipboard zurückruft und das DataObject
// freigibt und damit würde es einen Deadlock in onReleaseDataObject geben
// FlushClipboard muß synchron sein, damit das runterfahren ggf. erst weitergeht,
// wenn alle Clipboard-Formate gerendert wurden
// die Abfrage ist nötig, damit nur geflusht wird, wenn wir wirklich Clipboardowner
// die Abfrage ist nötig, damit nur geflusht wird, wenn wir wirklich Clipboardowner
// sind (ich weiss nicht genau was passiert, wenn man flusht und nicht Clipboard
// owner ist).
// eventuell kann man aber die Abfrage in den Clipboard STA Thread verlagern, indem

View File

@ -39,7 +39,7 @@
#include <com/sun/star/datatransfer/XTransferable.hpp>
#include <com/sun/star/datatransfer/clipboard/XClipboardListener.hpp>
#include <com/sun/star/datatransfer/clipboard/XClipboardOwner.hpp>
#include "..\..\inc\MtaOleClipb.hxx"
#include "../../inc/MtaOleClipb.hxx"
#if defined _MSC_VER
#pragma warning(push,1)

View File

@ -1,3 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -81,23 +81,8 @@ namespace
}
}
//-----------------------------------------------------------------------------------------------------------
// the 3 important functions which will be exported
//-----------------------------------------------------------------------------------------------------------
extern "C"
{
//----------------------------------------------------------------------
// component_getImplementationEnvironment
//----------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//----------------------------------------------------------------------
// component_getFactory
// returns a factory to create XFilePicker-Services

View File

@ -63,16 +63,6 @@ sal_Bool SAL_CALL component_canUnload( TimeValue *pTime )
return g_moduleCount.canUnload( &g_moduleCount , pTime );
}
//----------------------------------------------------------------------
// component_getImplementationEnvironment
//----------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//----------------------------------------------------------------------
// component_getFactory
// returns a factory to create XFilePicker-Services

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -36,10 +36,10 @@
#include <rtl/process.h>
#include "DOTransferable.hxx"
#include "..\misc\ImplHelper.hxx"
#include "..\misc\WinClip.hxx"
#include "../misc/ImplHelper.hxx"
#include "../misc/WinClip.hxx"
#include "DTransHelper.hxx"
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
#include "TxtCnvtHlp.hxx"
#include "MimeAttrib.hxx"
#include "FmtFilter.hxx"

View File

@ -41,7 +41,7 @@
#if defined _MSC_VER
#pragma warning(pop)
#endif
#include "..\misc\WinClip.hxx"
#include "../misc/WinClip.hxx"
//------------------------------------------------------------------------
// defines

View File

@ -36,8 +36,8 @@
#include <rtl/string.hxx>
#include <osl/diagnose.h>
#include <rtl/tencinfo.h>
#include "..\misc\ImplHelper.hxx"
#include "..\misc\WinClip.hxx"
#include "../misc/ImplHelper.hxx"
#include "../misc/WinClip.hxx"
#include "MimeAttrib.hxx"
#include "DTransHelper.hxx"
#include <rtl/string.h>

View File

@ -32,7 +32,7 @@
//------------------------------------------------------------------------
// includes
//------------------------------------------------------------------------
#include "..\..\inc\DtObjFactory.hxx"
#include "../../inc/DtObjFactory.hxx"
#include "XTDataObject.hxx"

View File

@ -34,7 +34,7 @@
//------------------------------------------------------------------------
#include <osl/diagnose.h>
#include "Fetc.hxx"
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
//------------------------------------------------------------------------
//

View File

@ -39,8 +39,8 @@
#include <com/sun/star/datatransfer/XMimeContentType.hpp>
#include "DataFmtTransl.hxx"
#include "..\misc\ImplHelper.hxx"
#include "..\misc\WinClip.hxx"
#include "../misc/ImplHelper.hxx"
#include "../misc/WinClip.hxx"
#include <algorithm>

View File

@ -36,9 +36,9 @@
#pragma warning(push,1)
#pragma warning(disable:4917)
#endif
#include <Shobjidl.h>
#include <shobjidl.h>
#include <shlguid.h>
#include <ObjIdl.h>
#include <objidl.h>
#include <shellapi.h>
#if defined _MSC_VER
#pragma warning(pop)

View File

@ -35,7 +35,7 @@
#include <osl/diagnose.h>
#include "TxtCnvtHlp.hxx"
#include "DTransHelper.hxx"
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
using namespace ::com::sun::star::datatransfer;
using namespace ::com::sun::star::uno;

View File

@ -30,9 +30,9 @@
#include "precompiled_dtrans.hxx"
#include <osl/diagnose.h>
#include "XNotifyingDataObject.hxx"
#include "..\clipb\WinClipbImpl.hxx"
#include "..\clipb\WinClipboard.hxx"
#include "..\..\inc\DtObjFactory.hxx"
#include "../clipb/WinClipbImpl.hxx"
#include "../clipb/WinClipboard.hxx"
#include "../../inc/DtObjFactory.hxx"
#ifdef __MINGW32__
#define __uuidof(I) IID_##I

View File

@ -36,7 +36,7 @@
#include "XTDataObject.hxx"
#include <com/sun/star/datatransfer/DataFlavor.hpp>
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
#include "DTransHelper.hxx"
#include "TxtCnvtHlp.hxx"
#include <com/sun/star/datatransfer/clipboard/XClipboardEx.hpp>

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -36,7 +36,7 @@
#include "ftransl.hxx"
#include <com/sun/star/datatransfer/XMimeContentType.hpp>
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
#if defined _MSC_VER
#pragma warning(push,1)

View File

@ -40,7 +40,7 @@
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/datatransfer/XDataFormatTranslator.hpp>
#include <com/sun/star/datatransfer/XMimeContentTypeFactory.hpp>
#include "..\misc\WinClip.hxx"
#include "../misc/WinClip.hxx"
#include <vector>

View File

@ -84,23 +84,8 @@ namespace
}
}
//-----------------------------------------------------------------------------------------------------------
// the 3 important functions which will be exported
//-----------------------------------------------------------------------------------------------------------
extern "C"
{
//----------------------------------------------------------------------
// component_getImplementationEnvironment
//----------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//----------------------------------------------------------------------
// component_getFactory
// returns a factory to create XFilePicker-Services

View File

@ -47,7 +47,7 @@
#pragma warning(pop)
#endif
#ifdef __MINGW32__
#include <excpt.h>
#include <sehandler.hxx>
#endif
//------------------------------------------------------------------------
@ -188,7 +188,7 @@ sal_Bool SAL_CALL IsOEMCP( sal_uInt32 codepage )
869, 874, 932, 936, 949, 950, 1361 };
for ( sal_Int8 i = 0; i < ( sizeof( arrOEMCP )/sizeof( sal_uInt32 ) ); ++i )
if ( arrOEMCP[i] == codepage )
if ( (sal_uInt32) arrOEMCP[i] == codepage )
return sal_True;
return sal_False;

View File

@ -50,7 +50,7 @@
//#define UNICODE
#include <osl/diagnose.h>
#include "..\..\inc\MtaOleClipb.hxx"
#include "../../inc/MtaOleClipb.hxx"
#include <osl/conditn.hxx>
#include <wchar.h>

View File

@ -34,7 +34,7 @@
//------------------------------------------------------------------------
#include <osl/diagnose.h>
#include "..\DTransHelper.hxx"
#include "../DTransHelper.hxx"
#include "XTDo.hxx"

View File

@ -35,7 +35,7 @@
//_________________________________________________________________________________________________________________________
#include "..\misc\ImplHelper.hxx"
#include "../misc/ImplHelper.hxx"
//_________________________________________________________________________________________________________________________
// other includes

View File

@ -53,7 +53,7 @@
#include <process.h>
#include "..\..\source\win32\ImplHelper.hxx"
#include "../../source/win32/ImplHelper.hxx"
//-------------------------------------------------------------

View File

@ -1,2 +1 @@
component_getImplementationEnvironment
component_getFactory

View File

@ -78,7 +78,7 @@
/* It must be safe to include this file in plain C code, so only C style
* comments are used. Do NOT use // C++ style comments. */
/* disable typedef for usage in svx/source/dialog/langtab.src */
/* disable typedef for usage in svtools/source/misc/langtab.src */
#ifndef RSC_RESOURCE_USAGE
typedef unsigned short LanguageType;
#endif

View File

@ -75,9 +75,7 @@ public:
special value.
@descr: NOTE: The "system" values may be overridden by the
application's configuration. If you need to access the system
values use <method>getRealLanguageWithoutConfig()</method>
instead.
application's configuration.
@returns
case LANGUAGE_PROCESS_OR_USER_DEFAULT : configured or system language
@ -154,13 +152,6 @@ public:
static ::com::sun::star::lang::Locale getFallbackLocale(
const ::com::sun::star::lang::Locale & rLocale );
/** Get fall-back LanguageType for LanguageType, resolving LANGUAGE_SYSTEM.
Returns the same LanguageType if an exact match was found.
*/
static LanguageType getFallbackLanguage( LanguageType nLang );
// -----------------------------
// - ConvertLanguageToIsoNames -
// -----------------------------
@ -184,34 +175,9 @@ public:
const rtl::OString& rCountry );
static LanguageType convertIsoStringToLanguage(
const rtl::OUString& rString, sal_Unicode cSep = '-' );
static LanguageType convertIsoByteStringToLanguage(
const rtl::OString& rString, sal_Char cSep = '-' );
static LanguageType convertUnxByteStringToLanguage(
const rtl::OString& rString );
/** @short: A real language/locale if the nLang parameter designates some
special value.
@descr: NOTE: This is a raw interface to the system and does not take
any application configuration into account. If that is wanted,
which is most likely, use <method>getRealLanguage()</method>
instead.
@returns
case LANGUAGE_PROCESS_OR_USER_DEFAULT : getSystemLanguage()
case LANGUAGE_SYSTEM_DEFAULT : getSystemLanguage()
case LANGUAGE_SYSTEM : getSystemLanguage()
case LANGUAGE_NONE : getSystemUILanguage()
case LANGUAGE_DONTKNOW : LANGUAGE_ENGLISH_US
else: nLang
In case getSystemLanguage() or getSystemUILanguage() returned
LANGUAGE_DONTKNOW, LANGUAGE_ENGLISH_US is returned instead.
*/
static LanguageType getRealLanguageWithoutConfig( LanguageType nLang );
static LanguageType resolveSystemLanguageByScriptType( LanguageType nLang, sal_Int16 nType );

View File

@ -1,4 +1,4 @@
inp i18npool : bridges sax stoc comphelper CPPUNIT:cppunit ICU:icu i18nutil regexp cpputools LIBXSLT:libxslt NULL
inp i18npool : bridges sax stoc comphelper CPPUNIT:cppunit ICU:icu i18nutil regexp DESKTOP:cpputools LIBXSLT:libxslt NULL
inp i18npool usr1 - all inp_mkout NULL
inp i18npool\inc nmake - all inp_inc NULL
inp i18npool\source\registerservices nmake - all inp_rserv inp_inc NULL

View File

@ -40,11 +40,13 @@ mkdir: %_DEST%\inc\i18npool
..\%__SRC%\bin\i18nisol*.dll %_DEST%\bin\i18nisol*.dll
..\%__SRC%\lib\libi18nisolang*.so %_DEST%\lib\libi18nisolang*.so
..\%__SRC%\lib\libi18nisolang*.dylib %_DEST%\lib\libi18nisolang*.dylib
..\%__SRC%\lib\libi18nisolang*.a %_DEST%\lib\libi18nisolang*.a
..\%__SRC%\lib\ii18npaper*.lib %_DEST%\lib\ii18npaper*.lib
..\%__SRC%\bin\i18npaper*.dll %_DEST%\bin\i18npaper*.dll
..\%__SRC%\lib\libi18npaper*.so %_DEST%\lib\libi18npaper*.so
..\%__SRC%\lib\libi18npaper*.dylib %_DEST%\lib\libi18npaper*.dylib
..\%__SRC%\lib\libi18npaper*.a %_DEST%\lib\libi18npaper*.a
..\%__SRC%\misc\i18npool.component %_DEST%\xml\i18npool.component
..\%__SRC%\misc\i18nsearch.component %_DEST%\xml\i18nsearch.component

View File

@ -57,11 +57,13 @@ public:
void testLineBreaking();
void testGraphemeIteration();
void testWeak();
void testAsian();
CPPUNIT_TEST_SUITE(TestBreakIterator);
CPPUNIT_TEST(testLineBreaking);
CPPUNIT_TEST(testGraphemeIteration);
CPPUNIT_TEST(testWeak);
CPPUNIT_TEST(testAsian);
CPPUNIT_TEST_SUITE_END();
private:
@ -104,7 +106,7 @@ void TestBreakIterator::testGraphemeIteration()
aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IN"));
{
sal_Unicode BA_HALANT_LA[] = { 0x09AC, 0x09CD, 0x09AF };
const sal_Unicode BA_HALANT_LA[] = { 0x09AC, 0x09CD, 0x09AF };
::rtl::OUString aTest1(BA_HALANT_LA, SAL_N_ELEMENTS(BA_HALANT_LA));
sal_Int32 nDone=0;
@ -118,7 +120,7 @@ void TestBreakIterator::testGraphemeIteration()
}
{
sal_Unicode HA_HALANT_NA_VOWELSIGNI[] = { 0x09B9, 0x09CD, 0x09A3, 0x09BF };
const sal_Unicode HA_HALANT_NA_VOWELSIGNI[] = { 0x09B9, 0x09CD, 0x09A3, 0x09BF };
::rtl::OUString aTest1(HA_HALANT_NA_VOWELSIGNI, SAL_N_ELEMENTS(HA_HALANT_NA_VOWELSIGNI));
sal_Int32 nDone=0;
@ -132,7 +134,7 @@ void TestBreakIterator::testGraphemeIteration()
}
{
sal_Unicode TA_HALANT_MA_HALANT_YA [] = { 0x09A4, 0x09CD, 0x09AE, 0x09CD, 0x09AF };
const sal_Unicode TA_HALANT_MA_HALANT_YA [] = { 0x09A4, 0x09CD, 0x09AE, 0x09CD, 0x09AF };
::rtl::OUString aTest1(TA_HALANT_MA_HALANT_YA, SAL_N_ELEMENTS(TA_HALANT_MA_HALANT_YA));
sal_Int32 nDone=0;
@ -156,10 +158,12 @@ void TestBreakIterator::testWeak()
aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("US"));
{
sal_Unicode WEAKS[] =
const sal_Unicode WEAKS[] =
{
0x0001, 0x0002,
0x0020, 0x00A0,
0x2150, 0x215F, //Number Forms, fractions
0x2160, 0x2180, //Number Forms, roman numerals
0x2200, 0x22FF, //Mathematical Operators
0x27C0, 0x27EF, //Miscellaneous Mathematical Symbols-A
0x2980, 0x29FF, //Miscellaneous Mathematical Symbols-B
@ -184,6 +188,45 @@ void TestBreakIterator::testWeak()
}
}
//A test to ensure that certain ranges and codepoints that are categorized as
//asian remain as asian, so that existing docs that depend on this don't silently
//change font for those asian chars.
//See https://bugs.freedesktop.org/show_bug.cgi?id=38095
void TestBreakIterator::testAsian()
{
lang::Locale aLocale;
aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en"));
aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("US"));
{
const sal_Unicode ASIANS[] =
{
//some typical CJK chars
0x4E00, 0x62FF,
//The full HalfWidth and FullWidth block has historically been
//designated as taking the CJK font :-(
//HalfWidth and FullWidth forms of ASCII 0-9, categorized under
//UAX24 as "Common" i.e. by that logic WEAK
0xFF10, 0xFF19,
//HalfWidth and FullWidth forms of ASCII A-z, categorized under
//UAX25 as "Latin", i.e. by that logic LATIN
0xFF21, 0xFF5A
};
::rtl::OUString aAsians(ASIANS, SAL_N_ELEMENTS(ASIANS));
for (sal_Int32 i = 0; i < aAsians.getLength(); ++i)
{
sal_Int16 nScript = m_xBreak->getScriptType(aAsians, i);
rtl::OStringBuffer aMsg;
aMsg.append(RTL_CONSTASCII_STRINGPARAM("Char 0x"));
aMsg.append(static_cast<sal_Int32>(aAsians.getStr()[i]), 16);
aMsg.append(RTL_CONSTASCII_STRINGPARAM(" should have been asian"));
CPPUNIT_ASSERT_MESSAGE(aMsg.getStr(),
nScript == i18n::ScriptType::ASIAN);
}
}
}
TestBreakIterator::TestBreakIterator()
{
m_xContext = cppu::defaultBootstrap_InitialComponentContext();

View File

@ -443,67 +443,155 @@ sal_Int16 SAL_CALL BreakIteratorImpl::getWordType( const OUString& /*Text*/,
return 0;
}
static sal_Int16 scriptTypes[] = {
ScriptType::WEAK, ScriptType::WEAK, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::ASIAN, ScriptType::LATIN, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::LATIN,
// 15
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::ASIAN, ScriptType::COMPLEX,
ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN,
// 30
ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 45
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN,
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 60
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::ASIAN,
// 75
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 90
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::WEAK, ScriptType::WEAK, ScriptType::COMPLEX,
// 105
ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN,
// 120
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::WEAK, ScriptType::WEAK,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 135
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX,
ScriptType::WEAK};
namespace
{
//See unicode/uscript.h
static sal_Int16 scriptTypes[] =
{
ScriptType::WEAK, ScriptType::WEAK, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::ASIAN, ScriptType::LATIN, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::LATIN,
// 15
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::ASIAN, ScriptType::COMPLEX,
ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN,
// 30
ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 45
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN,
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 60
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN, ScriptType::ASIAN,
// 75
ScriptType::COMPLEX, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::LATIN, ScriptType::LATIN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 90
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::WEAK, ScriptType::WEAK, ScriptType::COMPLEX,
// 105
ScriptType::ASIAN, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::ASIAN,
// 120
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::WEAK, ScriptType::WEAK,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
// 135
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX, ScriptType::COMPLEX,
ScriptType::COMPLEX,
ScriptType::WEAK
};
#define scriptListCount SAL_N_ELEMENTS(scriptTypes)
# define scriptTypesCount SAL_N_ELEMENTS(scriptTypes)
sal_Int16 getScriptClassByUAX24Script(sal_uInt32 currentChar)
{
sal_Int16 nRet;
int32_t script = u_getIntPropertyValue(currentChar, UCHAR_SCRIPT);
if (script < 0)
nRet = ScriptType::WEAK;
else if (static_cast<size_t>(script) >= SAL_N_ELEMENTS(scriptTypes))
nRet = ScriptType::COMPLEX; // anything new is going to be pretty wild
else
nRet = scriptTypes[script];
return nRet;
}
struct UBlock2Script
{
UBlockCode from;
UBlockCode to;
sal_Int16 script;
};
static UBlock2Script scriptList[] =
{
{UBLOCK_NO_BLOCK, UBLOCK_NO_BLOCK, ScriptType::WEAK},
{UBLOCK_BASIC_LATIN, UBLOCK_ARMENIAN, ScriptType::LATIN},
{UBLOCK_HEBREW, UBLOCK_MYANMAR, ScriptType::COMPLEX},
{UBLOCK_GEORGIAN, UBLOCK_GEORGIAN, ScriptType::LATIN},
{UBLOCK_HANGUL_JAMO, UBLOCK_HANGUL_JAMO, ScriptType::ASIAN},
{UBLOCK_ETHIOPIC, UBLOCK_ETHIOPIC, ScriptType::COMPLEX},
{UBLOCK_CHEROKEE, UBLOCK_RUNIC, ScriptType::LATIN},
{UBLOCK_KHMER, UBLOCK_MONGOLIAN, ScriptType::COMPLEX},
{UBLOCK_LATIN_EXTENDED_ADDITIONAL, UBLOCK_GREEK_EXTENDED, ScriptType::LATIN},
{UBLOCK_NUMBER_FORMS, UBLOCK_NUMBER_FORMS, ScriptType::WEAK},
{UBLOCK_CJK_RADICALS_SUPPLEMENT, UBLOCK_HANGUL_SYLLABLES, ScriptType::ASIAN},
{UBLOCK_CJK_COMPATIBILITY_IDEOGRAPHS, UBLOCK_CJK_COMPATIBILITY_IDEOGRAPHS, ScriptType::ASIAN},
{UBLOCK_ARABIC_PRESENTATION_FORMS_A, UBLOCK_ARABIC_PRESENTATION_FORMS_A, ScriptType::COMPLEX},
{UBLOCK_CJK_COMPATIBILITY_FORMS, UBLOCK_CJK_COMPATIBILITY_FORMS, ScriptType::ASIAN},
{UBLOCK_ARABIC_PRESENTATION_FORMS_B, UBLOCK_ARABIC_PRESENTATION_FORMS_B, ScriptType::COMPLEX},
{UBLOCK_HALFWIDTH_AND_FULLWIDTH_FORMS, UBLOCK_HALFWIDTH_AND_FULLWIDTH_FORMS, ScriptType::ASIAN},
{UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B, UBLOCK_CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT, ScriptType::ASIAN},
{UBLOCK_CJK_STROKES, UBLOCK_CJK_STROKES, ScriptType::ASIAN},
{UBLOCK_LATIN_EXTENDED_C, UBLOCK_LATIN_EXTENDED_D, ScriptType::LATIN}
};
#define scriptListCount SAL_N_ELEMENTS(scriptList)
//always sets rScriptType
//
//returns true for characters historically explicitly assigned to
//latin/weak/asian
//
//returns false for characters that historically implicitly assigned to
//weak as unknown
bool getCompatibilityScriptClassByBlock(sal_uInt32 currentChar, sal_Int16 &rScriptType)
{
bool bKnown = true;
//handle specific characters always as weak:
// 0x01 - this breaks a word
// 0x02 - this can be inside a word
// 0x20 & 0xA0 - Bug 102975, declare western space and non-break space as WEAK char.
if( 0x01 == currentChar || 0x02 == currentChar || 0x20 == currentChar || 0xA0 == currentChar)
rScriptType = ScriptType::WEAK;
// workaround for Coptic
else if ( 0x2C80 <= currentChar && 0x2CE3 >= currentChar)
rScriptType = ScriptType::LATIN;
else
{
UBlockCode block=ublock_getCode(currentChar);
size_t i = 0;
while (i < scriptListCount)
{
if (block <= scriptList[i].to)
break;
++i;
}
if (i < scriptListCount && block >= scriptList[i].from)
rScriptType = scriptList[i].script;
else
{
rScriptType = ScriptType::WEAK;
bKnown = false;
}
}
return bKnown;
}
}
sal_Int16 BreakIteratorImpl::getScriptClass(sal_uInt32 currentChar)
{
static sal_uInt32 lastChar = 0;
static sal_Int16 nRet = 0;
static sal_uInt32 lastChar = 0;
static sal_Int16 nRet = 0;
if (currentChar != lastChar) {
lastChar = currentChar;
if (currentChar != lastChar)
{
lastChar = currentChar;
int32_t script = u_getIntPropertyValue(currentChar, UCHAR_SCRIPT);
if (script < 0)
nRet = ScriptType::WEAK;
else if (static_cast<size_t>(script) >= SAL_N_ELEMENTS(scriptTypes))
nRet = ScriptType::COMPLEX; // anything new is going to be pretty wild
else
nRet = scriptTypes[script];
}
return nRet;
if (!getCompatibilityScriptClassByBlock(currentChar, nRet))
nRet = getScriptClassByUAX24Script(currentChar);
}
return nRet;
}
static inline sal_Bool operator == (const Locale& l1, const Locale& l2) {

View File

@ -34,7 +34,7 @@ LIBTARGET=NO
.INCLUDE : settings.mk
# Fix heap limit problem on MSC
.IF "$(OS)" == "WNT"
.IF "$(COM)" == "MSC"
.IF "$(COMEX)" != "8"
CDEFS+=-Zm300
.ENDIF

View File

@ -57,6 +57,8 @@ SLOFILES= \
$(SLO)/xdictionary.obj \
$(subst,$(MISC)/,$(SLO)/ $(MY_MISC_CXXFILES:s/.c/.obj/))
.IF "$(CROSS_COMPILING)" != "YES"
OBJFILES = $(OBJ)/gendict.obj
APP1TARGET = gendict
@ -67,6 +69,8 @@ APP1OBJS = $(DEPOBJFILES)
APP1STDLIBS = $(SALLIB)
.ENDIF
# --- Targets ------------------------------------------------------
.IF "$(SYSTEM_ICU)" == "YES"

View File

@ -33,7 +33,7 @@ TARGET=collator_data
.INCLUDE : settings.mk
# Fix heap limit problem on MSC
.IF "$(OS)" == "WNT"
.IF "$(COM)" == "MSC"
.IF "$(COMEX)" != "8"
CDEFS+=-Zm300
.ENDIF

View File

@ -49,6 +49,8 @@ SLOFILES= \
$(SLO)$/chaptercollator.obj \
$(rules_obj)
.IF "$(CROSS_COMPILING)" != "YES"
APP1TARGET = gencoll_rule
APP1RPATH = NONE
@ -61,6 +63,8 @@ APP1STDLIBS = $(SALLIB) \
$(ICUUCLIB) \
$(ICUDATALIB)
.ENDIF
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk

View File

@ -34,7 +34,7 @@ LIBTARGET=NO
.INCLUDE : settings.mk
# Fix heap limit problem on MSC
.IF "$(OS)" == "WNT"
.IF "$(COM)" == "MSC"
.IF "$(COMEX)" != "8"
CDEFS+=-Zm300
.ENDIF

View File

@ -37,7 +37,6 @@ ENABLE_EXCEPTIONS=TRUE
.INCLUDE : settings.mk
# --- Files --------------------------------------------------------
SLOFILES= \
@ -47,6 +46,8 @@ SLOFILES= \
$(SLO)$/indexentrysupplier_default.obj \
$(SLO)$/indexentrysupplier_common.obj
.IF "$(CROSS_COMPILING)" != "YES"
OBJFILES = $(OBJ)$/genindex_data.obj
APP1TARGET = genindex_data
@ -60,6 +61,8 @@ APP1STDLIBS = $(SALLIB) \
$(ICUUCLIB) \
$(ICUDATALIB)
.ENDIF
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk

View File

@ -1012,26 +1012,6 @@ LanguageType MsLangId::convertIsoStringToLanguage(
// -----------------------------------------------------------------------
// static
LanguageType MsLangId::convertIsoByteStringToLanguage(
const rtl::OString& rString, sal_Char cSep )
{
rtl::OString aLang;
rtl::OString aCountry;
sal_Int32 nSepPos = rString.indexOf( cSep );
if ( nSepPos >= 0 )
{
aLang = rString.copy( 0, nSepPos );
aCountry = rString.copy( nSepPos+1 );
}
else
aLang = rString;
return convertIsoNamesToLanguage( aLang, aCountry );
}
// -----------------------------------------------------------------------
struct IsoLangGLIBCModifiersEntry
{
LanguageType mnLang;

View File

@ -43,7 +43,11 @@ SLOFILES= $(SLO)$/insys.obj \
$(SLO)$/mslangid.obj
SHL1TARGET= $(ISOLANG_TARGET)$(ISOLANG_MAJOR)$(COMID)
.IF "$(COM)" == "MSC"
SHL1IMPLIB= i$(ISOLANG_TARGET)
.ELSE
SHL1IMPLIB= $(ISOLANG_TARGET)$(ISOLANG_MAJOR)$(COMID)
.ENDIF
DEF1DEPN= $(MISC)$/$(SHL1TARGET).flt
SHL1DEF= $(MISC)$/$(SHL1TARGET).def

View File

@ -90,29 +90,6 @@ inline LanguageType MsLangId::simplifySystemLanguages( LanguageType nLang )
return nLang;
}
// static
LanguageType MsLangId::getRealLanguageWithoutConfig( LanguageType nLang )
{
switch (simplifySystemLanguages( nLang))
{
case LANGUAGE_SYSTEM :
nLang = getSystemLanguage();
break;
case LANGUAGE_NONE :
nLang = getSystemUILanguage();
break;
default:
/* TODO: would this be useful here? */
//nLang = MsLangId::getReplacementForObsoleteLanguage( nLang);
; // nothing
}
if (nLang == LANGUAGE_DONTKNOW)
nLang = LANGUAGE_ENGLISH_US;
return nLang;
}
// static
LanguageType MsLangId::getRealLanguage( LanguageType nLang )
{
@ -252,14 +229,6 @@ LanguageType MsLangId::convertLocaleToLanguageWithFallback(
return lookupFallbackLocale( rLocale);
}
// static
LanguageType MsLangId::getFallbackLanguage( LanguageType nLang )
{
return lookupFallbackLanguage( MsLangId::getRealLanguage( nLang));
}
// static
bool MsLangId::isRightToLeft( LanguageType nLang )
{

View File

@ -484,24 +484,24 @@ void LCCTYPENode::generateCode (const OFileWriter &of) const
"DoubleQuotationEnd is an ASCII character but DoubleQuotationStart is not.");
if (aQuoteStart.toChar() <= 127 && aQuoteEnd.toChar() <= 127)
fprintf( stderr, "Warning: %s\n",
"QuotationStart and QuotationEnd are both ASCII characters. Not necessarily an error, but unusual.");
"QuotationStart and QuotationEnd are both ASCII characters. Not necessarily an issue, but unusual.");
if (aDoubleQuoteStart.toChar() <= 127 && aDoubleQuoteEnd.toChar() <= 127)
fprintf( stderr, "Warning: %s\n",
"DoubleQuotationStart and DoubleQuotationEnd are both ASCII characters. Not necessarily an error, but unusual.");
"DoubleQuotationStart and DoubleQuotationEnd are both ASCII characters. Not necessarily an issue, but unusual.");
if (aQuoteStart == aQuoteEnd)
fprintf( stderr, "Warning: %s\n",
"QuotationStart equals QuotationEnd. Not necessarily an error, but unusual.");
"QuotationStart equals QuotationEnd. Not necessarily an issue, but unusual.");
if (aDoubleQuoteStart == aDoubleQuoteEnd)
fprintf( stderr, "Warning: %s\n",
"DoubleQuotationStart equals DoubleQuotationEnd. Not necessarily an error, but unusual.");
"DoubleQuotationStart equals DoubleQuotationEnd. Not necessarily an issue, but unusual.");
/* TODO: should equalness of single and double quotes be an error? Would
* need to adapt quite some locales' data. */
if (aQuoteStart == aDoubleQuoteStart)
fprintf( stderr, "Warning: %s\n",
"QuotationStart equals DoubleQuotationStart. Not necessarily an error, but unusual.");
"QuotationStart equals DoubleQuotationStart. Not necessarily an isue, but unusual.");
if (aQuoteEnd == aDoubleQuoteEnd)
fprintf( stderr, "Warning: %s\n",
"QuotationEnd equals DoubleQuotationEnd. Not necessarily an error, but unusual.");
"QuotationEnd equals DoubleQuotationEnd. Not necessarily an issue, but unusual.");
// Known good values, exclude ASCII single (U+0027, ') and double (U+0022, ") quotes.
int ic;
switch (ic = aQuoteStart.toChar())

View File

@ -0,0 +1,357 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Locale SYSTEM "locale.dtd">
<Locale versionDTD="2.0.3" allowUpdateFromCLDR="no" version="1.0">
<LC_INFO>
<Language>
<LangID>gd</LangID>
<DefaultName>Gaelic, Scottish</DefaultName>
</Language>
<Country>
<CountryID>GB</CountryID>
<DefaultName>United Kingdom</DefaultName>
</Country>
</LC_INFO>
<LC_CTYPE unoid="generic">
<Separators>
<DateSeparator>/</DateSeparator>
<ThousandSeparator>,</ThousandSeparator>
<DecimalSeparator>.</DecimalSeparator>
<TimeSeparator>:</TimeSeparator>
<Time100SecSeparator>.</Time100SecSeparator>
<ListSeparator>;</ListSeparator>
<LongDateDayOfWeekSeparator>, </LongDateDayOfWeekSeparator>
<LongDateDaySeparator>, </LongDateDaySeparator>
<LongDateMonthSeparator> </LongDateMonthSeparator>
<LongDateYearSeparator> </LongDateYearSeparator>
</Separators>
<Markers>
<QuotationStart></QuotationStart>
<QuotationEnd></QuotationEnd>
<DoubleQuotationStart></DoubleQuotationStart>
<DoubleQuotationEnd></DoubleQuotationEnd>
</Markers>
<TimeAM>m</TimeAM>
<TimePM>f</TimePM>
<MeasurementSystem>metric</MeasurementSystem>
</LC_CTYPE>
<LC_FORMAT replaceFrom="[CURRENCY]" replaceTo="[$£-43C]">
<FormatElement msgid="FixedFormatskey1" default="true" type="medium" usage="FIXED_NUMBER" formatindex="0">
<FormatCode>General</FormatCode>
</FormatElement>
<FormatElement msgid="FixedFormatskey2" default="true" type="short" usage="FIXED_NUMBER" formatindex="1">
<FormatCode>0</FormatCode>
</FormatElement>
<FormatElement msgid="FixedFormatskey3" default="false" type="medium" usage="FIXED_NUMBER" formatindex="2">
<FormatCode>0.00</FormatCode>
</FormatElement>
<FormatElement msgid="FixedFormatskey4" default="false" type="short" usage="FIXED_NUMBER" formatindex="3">
<FormatCode>#,##0</FormatCode>
</FormatElement>
<FormatElement msgid="FixedFormatskey5" default="false" type="medium" usage="FIXED_NUMBER" formatindex="4">
<FormatCode>#,##0.00</FormatCode>
</FormatElement>
<FormatElement msgid="FixedFormatskey6" default="false" type="medium" usage="FIXED_NUMBER" formatindex="5">
<FormatCode>#,###.00</FormatCode>
</FormatElement>
<FormatElement msgid="ScientificFormatskey1" default="true" type="medium" usage="SCIENTIFIC_NUMBER" formatindex="6">
<FormatCode>0.00E+00</FormatCode>
</FormatElement>
<FormatElement msgid="ScientificFormatskey2" default="false" type="medium" usage="SCIENTIFIC_NUMBER" formatindex="7">
<FormatCode>0.00E+000</FormatCode>
</FormatElement>
<FormatElement msgid="PercentFormatskey1" default="true" type="short" usage="PERCENT_NUMBER" formatindex="8">
<FormatCode>0%</FormatCode>
</FormatElement>
<FormatElement msgid="PercentFormatskey2" default="true" type="long" usage="PERCENT_NUMBER" formatindex="9">
<FormatCode>0.00%</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey1" default="true" type="short" usage="CURRENCY" formatindex="12">
<FormatCode>[CURRENCY]#,##0;-[CURRENCY]#,##0</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey2" default="false" type="medium" usage="CURRENCY" formatindex="13">
<FormatCode>[CURRENCY]#,##0.00;-[CURRENCY]#,##0.00</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey3" default="false" type="medium" usage="CURRENCY" formatindex="14">
<FormatCode>[CURRENCY]#,##0;[RED]-[CURRENCY]#,##0</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey4" default="true" type="medium" usage="CURRENCY" formatindex="15">
<FormatCode>[CURRENCY]#,##0.00;[RED]-[CURRENCY]#,##0.00</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey5" default="false" type="medium" usage="CURRENCY" formatindex="16">
<FormatCode>CCC#,##0.00</FormatCode>
</FormatElement>
<FormatElement msgid="CurrencyFormatskey6" default="false" type="medium" usage="CURRENCY" formatindex="17">
<FormatCode>[CURRENCY]#,##0.--;[RED]-[CURRENCY]#,##0.--</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey11" default="true" type="short" usage="DATE" formatindex="18">
<FormatCode>D/MM/YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey14" default="true" type="long" usage="DATE" formatindex="19">
<FormatCode>NNNNDD, MMMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey6" default="true" type="medium" usage="DATE" formatindex="20">
<FormatCode>DD/MM/YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey5" default="false" type="medium" usage="DATE" formatindex="21">
<FormatCode>DD/MM/YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey15" default="false" type="long" usage="DATE" formatindex="22">
<FormatCode>D, MMM YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey16" default="false" type="long" usage="DATE" formatindex="23">
<FormatCode>D, MMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey21" default="false" type="long" usage="DATE" formatindex="24">
<FormatCode>D, MMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey17" default="false" type="long" usage="DATE" formatindex="25">
<FormatCode>D, MMMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey22" default="false" type="long" usage="DATE" formatindex="26">
<FormatCode>D, MMMM YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey10" default="false" type="medium" usage="DATE" formatindex="27">
<FormatCode>NN, DD/MMM/YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey18" default="false" type="long" usage="DATE" formatindex="28">
<FormatCode>NN, D, MMM YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey19" default="false" type="long" usage="DATE" formatindex="29">
<FormatCode>NN, D, MMMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey20" default="false" type="long" usage="DATE" formatindex="30">
<FormatCode>NNNND, MMMM YYYY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey12" default="false" type="short" usage="DATE" formatindex="31">
<FormatCode>MM/DD</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey7" default="false" type="medium" usage="DATE" formatindex="32">
<FormatCode>YY-MM-DD</FormatCode>
<DefaultName>ISO 8601</DefaultName>
</FormatElement>
<FormatElement msgid="DateFormatskey8" default="false" type="medium" usage="DATE" formatindex="33">
<FormatCode>YYYY-MM-DD</FormatCode>
<DefaultName>ISO 8601</DefaultName>
</FormatElement>
<FormatElement msgid="DateFormatskey1" default="false" type="medium" usage="DATE" formatindex="34">
<FormatCode>MM/YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey2" default="false" type="medium" usage="DATE" formatindex="35">
<FormatCode>MMM/DD</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey3" default="false" type="medium" usage="DATE" formatindex="36">
<FormatCode>MMMM</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey4" default="false" type="medium" usage="DATE" formatindex="37">
<FormatCode>QQ YY</FormatCode>
</FormatElement>
<FormatElement msgid="DateFormatskey9" default="false" type="medium" usage="DATE" formatindex="38">
<FormatCode>WW</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey1" default="false" type="short" usage="TIME" formatindex="39">
<FormatCode>HH:MM</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey2" default="false" type="medium" usage="TIME" formatindex="40">
<FormatCode>HH:MM:SS</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey3" default="true" type="short" usage="TIME" formatindex="41">
<FormatCode>HH:MM AM/PM</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey4" default="true" type="medium" usage="TIME" formatindex="42">
<FormatCode>HH:MM:SS AM/PM</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey5" default="false" type="medium" usage="TIME" formatindex="43">
<FormatCode>[HH]:MM:SS</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey6" default="false" type="short" usage="TIME" formatindex="44">
<FormatCode>MM:SS.00</FormatCode>
</FormatElement>
<FormatElement msgid="TimeFormatskey7" default="false" type="medium" usage="TIME" formatindex="45">
<FormatCode>[HH]:MM:SS.00</FormatCode>
</FormatElement>
<FormatElement msgid="DateTimeFormatskey1" default="true" type="medium" usage="DATE_TIME" formatindex="46">
<FormatCode>DD/MM/YY HH:MM</FormatCode>
</FormatElement>
<FormatElement msgid="DateTimeFormatskey2" default="false" type="medium" usage="DATE_TIME" formatindex="47">
<FormatCode>DD/MM/YYYY HH:MM:SS AM/PM</FormatCode>
</FormatElement>
</LC_FORMAT>
<LC_COLLATION>
<Collator default="true" unoid="alphanumeric"/>
<CollationOptions>
<TransliterationModules>IGNORE_CASE</TransliterationModules>
</CollationOptions>
</LC_COLLATION>
<LC_SEARCH>
<SearchOptions>
<TransliterationModules>IGNORE_CASE</TransliterationModules>
</SearchOptions>
</LC_SEARCH>
<LC_INDEX>
<IndexKey phonetic="false" default="true" unoid="alphanumeric">AÀÁBCDEÈÉFGHIJKÌLMNOÒÓPQRSTUÙVWXYZ</IndexKey>
<UnicodeScript>0</UnicodeScript>
<UnicodeScript>1</UnicodeScript>
<FollowPageWord>td</FollowPageWord>
<FollowPageWord>td</FollowPageWord>
</LC_INDEX>
<LC_CALENDAR>
<Calendar unoid="gregorian" default="true">
<DaysOfWeek>
<Day>
<DayID>sun</DayID>
<DefaultAbbrvName>DiD</DefaultAbbrvName>
<DefaultFullName>DiDòmhnaich</DefaultFullName>
</Day>
<Day>
<DayID>mon</DayID>
<DefaultAbbrvName>DiL</DefaultAbbrvName>
<DefaultFullName>DiLuain</DefaultFullName>
</Day>
<Day>
<DayID>tue</DayID>
<DefaultAbbrvName>DiM</DefaultAbbrvName>
<DefaultFullName>DiMàirt</DefaultFullName>
</Day>
<Day>
<DayID>wed</DayID>
<DefaultAbbrvName>DiC</DefaultAbbrvName>
<DefaultFullName>DiCiadain</DefaultFullName>
</Day>
<Day>
<DayID>thu</DayID>
<DefaultAbbrvName>Dia</DefaultAbbrvName>
<DefaultFullName>DiarDaoin</DefaultFullName>
</Day>
<Day>
<DayID>fri</DayID>
<DefaultAbbrvName>Dih</DefaultAbbrvName>
<DefaultFullName>DihAoine</DefaultFullName>
</Day>
<Day>
<DayID>sat</DayID>
<DefaultAbbrvName>DiS</DefaultAbbrvName>
<DefaultFullName>DiSathairne</DefaultFullName>
</Day>
</DaysOfWeek>
<MonthsOfYear>
<Month>
<MonthID>jan</MonthID>
<DefaultAbbrvName>Faoi</DefaultAbbrvName>
<DefaultFullName>Faoilleach</DefaultFullName>
</Month>
<Month>
<MonthID>feb</MonthID>
<DefaultAbbrvName>Gearr</DefaultAbbrvName>
<DefaultFullName>Gearran</DefaultFullName>
</Month>
<Month>
<MonthID>mar</MonthID>
<DefaultAbbrvName>Màrt</DefaultAbbrvName>
<DefaultFullName>Màrt</DefaultFullName>
</Month>
<Month>
<MonthID>apr</MonthID>
<DefaultAbbrvName>Gibl</DefaultAbbrvName>
<DefaultFullName>Giblean</DefaultFullName>
</Month>
<Month>
<MonthID>may</MonthID>
<DefaultAbbrvName>Cèit</DefaultAbbrvName>
<DefaultFullName>Cèitean</DefaultFullName>
</Month>
<Month>
<MonthID>jun</MonthID>
<DefaultAbbrvName>Ògmh</DefaultAbbrvName>
<DefaultFullName>Ògmhios</DefaultFullName>
</Month>
<Month>
<MonthID>jul</MonthID>
<DefaultAbbrvName>Iuch</DefaultAbbrvName>
<DefaultFullName>Iuchar</DefaultFullName>
</Month>
<Month>
<MonthID>aug</MonthID>
<DefaultAbbrvName>Lùna</DefaultAbbrvName>
<DefaultFullName>Lùnastal</DefaultFullName>
</Month>
<Month>
<MonthID>sep</MonthID>
<DefaultAbbrvName>Sult</DefaultAbbrvName>
<DefaultFullName>Sultain</DefaultFullName>
</Month>
<Month>
<MonthID>oct</MonthID>
<DefaultAbbrvName>Dàmh</DefaultAbbrvName>
<DefaultFullName>Dàmhair</DefaultFullName>
</Month>
<Month>
<MonthID>nov</MonthID>
<DefaultAbbrvName>Samh</DefaultAbbrvName>
<DefaultFullName>Samhain</DefaultFullName>
</Month>
<Month>
<MonthID>dec</MonthID>
<DefaultAbbrvName>Dùbh</DefaultAbbrvName>
<DefaultFullName>Dùbhlachd</DefaultFullName>
</Month>
</MonthsOfYear>
<Eras>
<Era>
<EraID>bc</EraID>
<DefaultAbbrvName>RC</DefaultAbbrvName>
<DefaultFullName>ro Chrìost</DefaultFullName>
</Era>
<Era>
<EraID>ad</EraID>
<DefaultAbbrvName>AD</DefaultAbbrvName>
<DefaultFullName>as dèidh Chrìost</DefaultFullName>
</Era>
</Eras>
<StartDayOfWeek>
<DayID>mon</DayID>
</StartDayOfWeek>
<MinimalDaysInFirstWeek>1</MinimalDaysInFirstWeek>
</Calendar>
</LC_CALENDAR>
<LC_CURRENCY>
<Currency default="true" usedInCompatibleFormatCodes="true">
<CurrencyID>GBP</CurrencyID>
<CurrencySymbol>£</CurrencySymbol>
<BankSymbol>GBP</BankSymbol>
<CurrencyName>Punnd Sasannach</CurrencyName>
<DecimalPlaces>2</DecimalPlaces>
</Currency>
</LC_CURRENCY>
<LC_TRANSLITERATION>
<Transliteration unoid="LOWERCASE_UPPERCASE"/>
<Transliteration unoid="UPPERCASE_LOWERCASE"/>
<Transliteration unoid="IGNORE_CASE"/>
</LC_TRANSLITERATION>
<LC_MISC>
<ReservedWords>
<trueWord>Fìor</trueWord>
<falseWord>Breug</falseWord>
<quarter1Word>Ràithe 1</quarter1Word>
<quarter2Word>Ràithe 2</quarter2Word>
<quarter3Word>Ràithe 3</quarter3Word>
<quarter4Word>Ràithe 4</quarter4Word>
<aboveWord>Os cionn</aboveWord>
<belowWord>Fo</belowWord>
<quarter1Abbreviation>R 1</quarter1Abbreviation>
<quarter2Abbreviation>R 2</quarter2Abbreviation>
<quarter3Abbreviation>R 3</quarter3Abbreviation>
<quarter4Abbreviation>R 4</quarter4Abbreviation>
</ReservedWords>
</LC_MISC>
<LC_NumberingLevel>
<NumberingLevel NumType="4" Prefix=" " Suffix=")"/>
<NumberingLevel NumType="4" Prefix=" " Suffix="."/>
<NumberingLevel NumType="4" Prefix="(" Suffix=")"/>
<NumberingLevel NumType="2" Prefix=" " Suffix="."/>
<NumberingLevel NumType="0" Prefix=" " Suffix=")"/>
<NumberingLevel NumType="1" Prefix=" " Suffix=")"/>
<NumberingLevel NumType="1" Prefix="(" Suffix=")"/>
<NumberingLevel NumType="3" Prefix=" " Suffix="."/>
</LC_NumberingLevel>
<LC_OutLineNumberingLevel ref="en_US"/>
</Locale>

View File

@ -31,6 +31,7 @@ getAllCalendars_fr_MC;
getAllCalendars_fur_IT;
getAllCalendars_fy_NL;
getAllCalendars_ga_IE;
getAllCalendars_gd_GB;
getAllCalendars_gsc_FR;
getAllCalendars_hr_HR;
getAllCalendars_hsb_DE;
@ -102,6 +103,7 @@ getAllCurrencies_fr_MC;
getAllCurrencies_fur_IT;
getAllCurrencies_fy_NL;
getAllCurrencies_ga_IE;
getAllCurrencies_gd_GB;
getAllCurrencies_gsc_FR;
getAllCurrencies_hr_HR;
getAllCurrencies_hsb_DE;
@ -173,6 +175,7 @@ getAllFormats0_fr_MC;
getAllFormats0_fur_IT;
getAllFormats0_fy_NL;
getAllFormats0_ga_IE;
getAllFormats0_gd_GB;
getAllFormats0_gsc_FR;
getAllFormats0_hr_HR;
getAllFormats0_hsb_DE;
@ -244,6 +247,7 @@ getBreakIteratorRules_fr_MC;
getBreakIteratorRules_fur_IT;
getBreakIteratorRules_fy_NL;
getBreakIteratorRules_ga_IE;
getBreakIteratorRules_gd_GB;
getBreakIteratorRules_gsc_FR;
getBreakIteratorRules_hr_HR;
getBreakIteratorRules_hsb_DE;
@ -315,6 +319,7 @@ getCollationOptions_fr_MC;
getCollationOptions_fur_IT;
getCollationOptions_fy_NL;
getCollationOptions_ga_IE;
getCollationOptions_gd_GB;
getCollationOptions_gsc_FR;
getCollationOptions_hr_HR;
getCollationOptions_hsb_DE;
@ -386,6 +391,7 @@ getCollatorImplementation_fr_MC;
getCollatorImplementation_fur_IT;
getCollatorImplementation_fy_NL;
getCollatorImplementation_ga_IE;
getCollatorImplementation_gd_GB;
getCollatorImplementation_gsc_FR;
getCollatorImplementation_hr_HR;
getCollatorImplementation_hsb_DE;
@ -457,6 +463,7 @@ getContinuousNumberingLevels_fr_MC;
getContinuousNumberingLevels_fur_IT;
getContinuousNumberingLevels_fy_NL;
getContinuousNumberingLevels_ga_IE;
getContinuousNumberingLevels_gd_GB;
getContinuousNumberingLevels_gsc_FR;
getContinuousNumberingLevels_hr_HR;
getContinuousNumberingLevels_hsb_DE;
@ -528,6 +535,7 @@ getFollowPageWords_fr_MC;
getFollowPageWords_fur_IT;
getFollowPageWords_fy_NL;
getFollowPageWords_ga_IE;
getFollowPageWords_gd_GB;
getFollowPageWords_gsc_FR;
getFollowPageWords_hr_HR;
getFollowPageWords_hsb_DE;
@ -599,6 +607,7 @@ getForbiddenCharacters_fr_MC;
getForbiddenCharacters_fur_IT;
getForbiddenCharacters_fy_NL;
getForbiddenCharacters_ga_IE;
getForbiddenCharacters_gd_GB;
getForbiddenCharacters_gsc_FR;
getForbiddenCharacters_hr_HR;
getForbiddenCharacters_hsb_DE;
@ -670,6 +679,7 @@ getIndexAlgorithm_fr_MC;
getIndexAlgorithm_fur_IT;
getIndexAlgorithm_fy_NL;
getIndexAlgorithm_ga_IE;
getIndexAlgorithm_gd_GB;
getIndexAlgorithm_gsc_FR;
getIndexAlgorithm_hr_HR;
getIndexAlgorithm_hsb_DE;
@ -741,6 +751,7 @@ getLCInfo_fr_MC;
getLCInfo_fur_IT;
getLCInfo_fy_NL;
getLCInfo_ga_IE;
getLCInfo_gd_GB;
getLCInfo_gsc_FR;
getLCInfo_hr_HR;
getLCInfo_hsb_DE;
@ -812,6 +823,7 @@ getLocaleItem_fr_MC;
getLocaleItem_fur_IT;
getLocaleItem_fy_NL;
getLocaleItem_ga_IE;
getLocaleItem_gd_GB;
getLocaleItem_gsc_FR;
getLocaleItem_hr_HR;
getLocaleItem_hsb_DE;
@ -883,6 +895,7 @@ getOutlineNumberingLevels_fr_MC;
getOutlineNumberingLevels_fur_IT;
getOutlineNumberingLevels_fy_NL;
getOutlineNumberingLevels_ga_IE;
getOutlineNumberingLevels_gd_GB;
getOutlineNumberingLevels_gsc_FR;
getOutlineNumberingLevels_hr_HR;
getOutlineNumberingLevels_hsb_DE;
@ -954,6 +967,7 @@ getReservedWords_fr_MC;
getReservedWords_fur_IT;
getReservedWords_fy_NL;
getReservedWords_ga_IE;
getReservedWords_gd_GB;
getReservedWords_gsc_FR;
getReservedWords_hr_HR;
getReservedWords_hsb_DE;
@ -1025,6 +1039,7 @@ getSearchOptions_fr_MC;
getSearchOptions_fur_IT;
getSearchOptions_fy_NL;
getSearchOptions_ga_IE;
getSearchOptions_gd_GB;
getSearchOptions_gsc_FR;
getSearchOptions_hr_HR;
getSearchOptions_hsb_DE;
@ -1096,6 +1111,7 @@ getTransliterations_fr_MC;
getTransliterations_fur_IT;
getTransliterations_fy_NL;
getTransliterations_ga_IE;
getTransliterations_gd_GB;
getTransliterations_gsc_FR;
getTransliterations_hr_HR;
getTransliterations_hsb_DE;
@ -1167,6 +1183,7 @@ getUnicodeScripts_fr_MC;
getUnicodeScripts_fur_IT;
getUnicodeScripts_fy_NL;
getUnicodeScripts_ga_IE;
getUnicodeScripts_gd_GB;
getUnicodeScripts_gsc_FR;
getUnicodeScripts_hr_HR;
getUnicodeScripts_hsb_DE;

View File

@ -36,7 +36,7 @@ LIBTARGET=NO
debug!=
.ENDIF
.IF "$(OS)" == "WNT"
.IF "$(OS_FOR_BUILD)" == "WNT"
my_file = file:///
.ELSE
my_file = file://
@ -167,6 +167,7 @@ SHL3OBJS= \
$(SLO)$/localedata_fur_IT.obj \
$(SLO)$/localedata_fy_NL.obj \
$(SLO)$/localedata_ga_IE.obj \
$(SLO)$/localedata_gd_GB.obj \
$(SLO)$/localedata_gsc_FR.obj \
$(SLO)$/localedata_hr_HR.obj \
$(SLO)$/localedata_hsb_DE.obj \
@ -326,12 +327,20 @@ MY_MISC_CXXFILES := $(foreach,i,$(DEPOBJFILES) $(MISC)/$(i:b).cxx)
.INCLUDE : target.mk
$(MY_MISC_CXXFILES) : $(OUT_FOR_BUILD)$/bin$/saxparser$(EXECPOST) $(MISC)/saxparser.rdb
$(MY_MISC_CXXFILES) : $(OUT_FOR_BUILD)$/bin$/saxparser$(EXECPOST_FOR_BUILD) $(MISC)/saxparser.rdb
.IF "$(CROSS_COMPILING)" == "YES"
# Always cross-compiling from some Unix,
# so the BUILD platform's lib directory is correct
sharedlibdir=$(SOLARLIBDIR_FOR_BUILD)
.ELSE
sharedlibdir=$(SOLARSHAREDBIN)
.ENDIF
$(MISC)$/localedata_%.cxx : %.xml
$(AUGMENT_LIBRARY_PATH) $(WRAPCMD) $(OUT_FOR_BUILD)$/bin$/saxparser $* $< $@ \
$(my_file)$(PWD)/$(MISC_FOR_BUILD)/saxparser.rdb $(SOLARBINDIR)$/types.rdb \
-env:OOO_INBUILD_SHAREDLIB_DIR=$(my_file)$(SOLARSHAREDBIN)
-env:OOO_INBUILD_SHAREDLIB_DIR=$(my_file)$(sharedlibdir)
$(RM) $(BIN)$/$(@:b).rdb
$(MISC)/saxparser.rdb .ERRREMOVE : $(SOLARENV)/bin/packcomponents.xslt \

View File

@ -149,6 +149,7 @@ static const struct {
{ "eu", lcl_DATA_EURO },
{ "fo_FO", lcl_DATA_EURO },
{ "ga_IE", lcl_DATA_EURO },
{ "gd_GB", lcl_DATA_EURO },
{ "ka_GE", lcl_DATA_EURO },
{ "be_BY", lcl_DATA_EURO },
{ "kl_GL", lcl_DATA_EURO },

View File

@ -58,6 +58,8 @@ CDEFS+=-D__STD_LIMITS
SLOFILES= $(SLO)$/localedata.obj
.IF "$(CROSS_COMPILING)" != "YES"
OBJFILES = \
$(OBJ)$/saxparser.obj \
$(OBJ)$/LocaleNode.obj \
@ -78,6 +80,8 @@ DEPOBJFILES = \
$(OBJ)$/LocaleNode.obj \
$(OBJ)$/filewriter.obj
.ENDIF
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk

View File

@ -44,7 +44,11 @@ SLOFILES=$(SLO)$/paper.obj
SHL1OBJS=$(SLOFILES)
SHL1TARGET=$(TARGET)$(DLLPOSTFIX)
.IF "$(COM)" == "MSC"
SHL1IMPLIB=i$(TARGET)
.ELSE
SHL1IMPLIB=$(TARGET)$(DLLPOSTFIX)
.ENDIF
DEF1DEPN=$(MISC)$/$(SHL1TARGET).flt
SHL1DEF=$(MISC)$/$(SHL1TARGET).def

View File

@ -247,7 +247,7 @@ PaperInfo PaperInfo::getSystemDefaultPaper()
// try user-defined locale setting
xConfigNA->getByName( CREATE_OUSTRING( "ooSetupSystemLocale" ) ) >>= aLocaleStr;
}
catch( Exception& )
catch(const Exception&)
{
}
@ -377,7 +377,9 @@ PaperInfo PaperInfo::getSystemDefaultPaper()
xConfigNA->getByName( CREATE_OUSTRING( "Locale" ) ) >>= aLocaleStr;
}
}
catch( Exception& ) {}
catch(const Exception&)
{
}
if (aLocaleStr.getLength() == 0)
aLocaleStr = CREATE_OUSTRING("en-US");

View File

@ -576,11 +576,6 @@ static const struct InstancesArray {
extern "C"
{
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment( const sal_Char** ppEnvTypeName, uno_Environment** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( const sal_Char* sImplementationName, void* _pServiceManager, void* /*_pRegistryKey*/ )
{
void* pRet = NULL;

View File

@ -982,12 +982,6 @@ SAL_CALL TextSearch_CreateInstance(
extern "C"
{
SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char** ppEnvTypeName, uno_Environment** /*ppEnv*/ )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( const sal_Char* sImplementationName,
void* _pServiceManager, void* /*_pRegistryKey*/ )
{

View File

@ -34,7 +34,7 @@ LIBTARGET=NO
.INCLUDE : settings.mk
# Fix heap limit problem on MSC
.IF "$(OS)" == "WNT"
.IF "$(COM)" == "MSC"
.IF "$(COMEX)" != "8"
CDEFS+=-Zm300
.ENDIF

View File

@ -44,6 +44,8 @@ SLOFILES= \
$(SLO)$/textconversion_ko.obj \
$(SLO)$/textconversion_zh.obj
.IF "$(CROSS_COMPILING)" != "YES"
OBJFILES = $(OBJ)$/genconv_dict.obj
APP1TARGET = genconv_dict
@ -53,6 +55,8 @@ APP1OBJS = $(OBJ)$/genconv_dict.obj
APP1STDLIBS = $(SALLIB)
.ENDIF
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk

View File

@ -57,10 +57,6 @@ public:
oneToOneMapping( OneToOneMappingTable_t *rpTable, const size_t rnSize, const size_t rnUnitSize = sizeof(OneToOneMappingTable_t) );
virtual ~oneToOneMapping();
// make index for fast search
// bluedawrf: not used
// void makeIndex();
// binary search
virtual sal_Unicode find( const sal_Unicode nKey ) const;

View File

@ -49,14 +49,6 @@ inline void SAL_CALL x_rtl_uString_new_WithLength( rtl_uString ** newStr, sal_In
*newStr = (rtl_uString*) rtl_allocateMemory ( sizeof(rtl_uString) + sizeof(sal_Unicode) * nLen);
(*newStr)->refCount = _refCount;
(*newStr)->length = nLen;
// rtl_uString is defined in rtl/ustring.h as below:
//typedef struct _rtl_uString
//{
// sal_Int32 refCount;
// sal_Int32 length;
// sal_Unicode buffer[1];
//} rtl_uString;
}
inline rtl_uString * SAL_CALL x_rtl_uString_new_WithLength( sal_Int32 nLen, sal_Int32 _refCount = 0 )
@ -76,6 +68,6 @@ inline void SAL_CALL x_rtl_uString_release( rtl_uString * value )
}
#endif // #ifndef _I18N_X_RTL_USTRING_H_
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View File

@ -1,3 +1,3 @@
inu i18nutil : sal cppu offuh NULL
inu i18nutil : sal cppu offapi NULL
inu i18nutil usr1 - all inu_mkout NULL
inu i18nutil\source\utility nmake - all inu_utility NULL

View File

@ -10,4 +10,5 @@ mkdir: %_DEST%\inc\i18nutil
..\%__SRC%\bin\i18nutil*.dll %_DEST%\bin\i18nutil*.dll
..\%__SRC%\lib\libi18nutil*.so %_DEST%\lib\libi18nutil*.so
..\%__SRC%\lib\libi18nutil*.dylib %_DEST%\lib\libi18nutil*.dylib
..\%__SRC%\lib\libi18nutil*.a %_DEST%\lib\libi18nutil*.a
..\%__SRC%\lib\ii18nutil.lib %_DEST%\lib\ii18nutil.lib

View File

@ -47,7 +47,11 @@ SLOFILES= \
# Unicode utilities
SHL1TARGET= $(TARGET)$(COMID)
.IF "$(COM)" == "MSC"
SHL1IMPLIB= i$(TARGET)
.ELSE
SHL1IMPLIB= $(TARGET)$(COMID)
.ENDIF
DEF1DEPN= $(MISC)$/$(SHL1TARGET).flt
SHL1DEF= $(MISC)$/$(SHL1TARGET).def

View File

@ -33,8 +33,7 @@
#include <boost/unordered_map.hpp>
#include <vector>
typedef boost::unordered_map<ByteString , ByteString , hashByteString,equalByteString>
ByteStringHashMap;
typedef boost::unordered_map<rtl::OString, rtl::OString, rtl::OStringHash> ByteStringHashMap;
//

View File

@ -84,8 +84,7 @@ class PFormEntrys;
class MergeData;
typedef std::set<ByteString , lessByteString > ByteStringSet;
typedef boost::unordered_map<ByteString , ByteString , hashByteString,equalByteString>
ByteStringHashMap;
typedef boost::unordered_map<rtl::OString, rtl::OString, rtl::OStringHash> ByteStringHashMap;
typedef boost::unordered_map<ByteString , bool , hashByteString,equalByteString>
ByteStringBoolHashMap;
@ -197,8 +196,8 @@ public:
void addFallbackData( ByteString& sId , const ByteString& sText );
bool getFallbackData( ByteString& sId , ByteString& sText);
void addMergedLanguage( ByteString& sLang );
bool isMerged( ByteString& sLang );
void addMergedLanguage(rtl::OString& rLang);
bool isMerged(rtl::OString& rLang);
ResData( const ByteString &rPF, const ByteString &rGId )
:
nWidth( 0 ),
@ -307,7 +306,7 @@ private:
sal_Bool bNextMustBeDefineEOL; // define but no \ at lineend
sal_uLong nLevel; // res. recursiv? how deep?
sal_uInt16 nList; // cur. res. is String- or FilterList
ByteString nListLang;
rtl::OString m_sListLang;
sal_uLong nListIndex;
sal_uLong nListLevel;
bool bSkipFile;
@ -345,23 +344,17 @@ public:
static void QuotHTML( ByteString &rString );
static bool CopyFile( const ByteString& source , const ByteString& dest );
static void QuotHTMLXRM( ByteString &rString );
static void UnquotHTML( ByteString &rString );
static const char* GetEnv( const char *pVar );
static int getCurrentDirectory( rtl::OUString& base_fqurl , rtl::OUString& base );
static bool isSourceLanguage( const ByteString &sLanguage );
static bool isAllowed( const ByteString &sLanguage );
static bool LanguageAllowed( const ByteString &nLanguage );
static void Languages( std::vector<ByteString>::const_iterator& begin , std::vector<ByteString>::const_iterator& end );
static void getRandomName( const ByteString& sPrefix , ByteString& sRandStr , const ByteString& sPostfix );
static void getRandomName( ByteString& sRandStr );
static void getCurrentDir( std::string& dir );
static void replaceEncoding( ByteString& rString );
static ByteString GetFallbackLanguage( const ByteString nLanguage );
static void FillInFallbacks( ResData *pResData );
static void FillInListFallbacks( ExportList *pList, const ByteString &nSource, const ByteString &nFallback );
@ -377,8 +370,6 @@ private:
static std::vector<ByteString> aLanguages;
static std::vector<ByteString> aForcedLanguages;
sal_Bool ListExists( ResData *pResData, sal_uInt16 nLst );
sal_Bool WriteData( ResData *pResData, sal_Bool bCreateNew = sal_False );// called befor dest. cur ResData
sal_Bool WriteExportList( ResData *pResData, ExportList *pExportList,
const ByteString &rTyp, sal_Bool bCreateNew = sal_False );
@ -393,13 +384,12 @@ private:
ByteString GetPairedListString ( const ByteString& sText );
ByteString StripList ( const ByteString& sText );
void UnmergeUTF8( ByteString& sOrig );
void InsertListEntry( const ByteString &rText, const ByteString &rLine );
void CleanValue( ByteString &rValue );
ByteString GetText( const ByteString &rSource, int nToken );
sal_Bool PrepareTextToMerge( ByteString &rText, sal_uInt16 nTyp,
ByteString &nLangIndex, ResData *pResData );
sal_Bool PrepareTextToMerge(ByteString &rText, sal_uInt16 nTyp,
rtl::OString &rLangIndex, ResData *pResData);
void MergeRest( ResData *pResData, sal_uInt16 nMode = MERGE_MODE_NORMAL );
void ConvertMergeContent( ByteString &rText );
@ -490,7 +480,6 @@ public:
MergeData( const ByteString &rTyp, const ByteString &rGID, const ByteString &rLID , const ByteString &rFilename )
: sTyp( rTyp ), sGID( rGID ), sLID( rLID ) , sFilename( rFilename ) {};
~MergeData();
PFormEntrys* InsertEntry( const ByteString &rPForm );
PFormEntrys* GetPFormEntrys( ResData *pResData );
void Insert( const ByteString& rPFO , PFormEntrys* pfEntrys );
@ -525,8 +514,6 @@ class MergeDataFile
const ByteString &sFilename, bool bCaseSensitive
);
ByteString Dump();
void WriteError( const ByteString &rLine );
public:
MergeDataFile( const ByteString &rFileName, const ByteString& rFile , sal_Bool bErrLog, CharSet aCharSet, bool bCaseSensitive = false );
~MergeDataFile();

View File

@ -48,13 +48,13 @@ private:
/// @PRECOND 0 < langIdx_in < MAX_IDX
static void FillInFallbacks( LangHashMap& rElem_out, ByteString sLangIdx_in );
/// Debugmethod, prints the content of the map to stdout
static void Dump( LangHashMap* rElem_in , const ByteString sKey_in );
/// Debugmethod, prints the content of the map to stdout
static void Dump( XMLHashMap* rElem_in ) ;
#if OSL_DEBUG_LEVEL > 2
/// Debugmethod, prints the content of the map to stdout
static void Dump(LangHashMap* rElem_in , const ByteString sKey_in);
/// Debugmethod, prints the content of the map to stdout
static void Dump(XMLHashMap* rElem_in);
#endif
public:
HelpParser( const ByteString &rHelpFile, bool bUTF8 , bool bHasInputList );
@ -79,7 +79,6 @@ private:
ByteString GetOutpath( const ByteString& rPathX , const ByteString& sCur , const ByteString& rPathY );
bool MergeSingleFile( XMLFile* file , MergeDataFile& aMergeDataFile , const ByteString& sLanguage , ByteString sPath );
void Process( LangHashMap* aLangHM , const ByteString& sCur , ResData *pResData , MergeDataFile& aMergeDataFile );
void ProcessHelp( LangHashMap* aLangHM , const ByteString& sCur , ResData *pResData , MergeDataFile& aMergeDataFile );
void MakeDir( const ByteString& sPath );
};

Some files were not shown because too many files have changed in this diff Show More