/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ #include #include #include ImplHatch::ImplHatch() : maColor ( COL_BLACK ), meStyle ( HatchStyle::Single ), mnDistance ( 1 ), mnAngle ( 0 ) { } ImplHatch::ImplHatch( const ImplHatch& rImplHatch ) : maColor ( rImplHatch.maColor ), meStyle ( rImplHatch.meStyle ), mnDistance ( rImplHatch.mnDistance ), mnAngle ( rImplHatch.mnAngle ) { } bool ImplHatch::operator==( const ImplHatch& rImplHatch ) const { return maColor == rImplHatch.maColor && meStyle == rImplHatch.meStyle && mnDistance == rImplHatch.mnDistance && mnAngle == rImplHatch.mnAngle; } Hatch::Hatch() : mpImplHatch() { } Hatch::Hatch( const Hatch& rHatch ) : mpImplHatch( rHatch.mpImplHatch ) { } Hatch::Hatch( HatchStyle eStyle, const Color& rColor, long nDistance, sal_uInt16 nAngle10 ) : mpImplHatch() { mpImplHatch->maColor = rColor; mpImplHatch->meStyle = eStyle; mpImplHatch->mnDistance = nDistance; mpImplHatch->mnAngle = nAngle10; } Hatch::~Hatch() { } Hatch& Hatch::operator=( const Hatch& rHatch ) { mpImplHatch = rHatch.mpImplHatch; return *this; } bool Hatch::operator==( const Hatch& rHatch ) const { return mpImplHatch == rHatch.mpImplHatch; } void Hatch::SetColor( const Color& rColor ) { mpImplHatch->maColor = rColor; } void Hatch::SetDistance( long nDistance ) { mpImplHatch->mnDistance = nDistance; } void Hatch::SetAngle( sal_uInt16 nAngle10 ) { mpImplHatch->mnAngle = nAngle10; } SvStream& ReadHatch( SvStream& rIStm, Hatch& rHatch ) { VersionCompat aCompat( rIStm, StreamMode::READ ); sal_uInt16 nTmp16; sal_Int32 nTmp32(0); rIStm.ReadUInt16( nTmp16 ); rHatch.mpImplHatch->meStyle = (HatchStyle) nTmp16; ReadColor( rIStm, rHatch.mpImplHatch->maColor ).ReadInt32( nTmp32 ).ReadUInt16( rHatch.mpImplHatch->mnAngle ); rHatch.mpImplHatch->mnDistance = nTmp32; return rIStm; } SvStream& WriteHatch( SvStream& rOStm, const Hatch& rHatch ) { VersionCompat aCompat( rOStm, StreamMode::WRITE, 1 ); rOStm.WriteUInt16( (sal_uInt16)rHatch.mpImplHatch->meStyle ); WriteColor( rOStm, rHatch.mpImplHatch->maColor ); rOStm.WriteInt32( rHatch.mpImplHatch->mnDistance ).WriteUInt16( rHatch.mpImplHatch->mnAngle ); return rOStm; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ ollabora/co-24.04.7'>distro/collabora/co-24.04.7 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
AgeCommit message (Expand)Author
2019-07-04Fix libgpg-error compilation error with gawk5nd101
2019-02-01Missing extern in external/libgpg-error (clang-cl)Stephan Bergmann
2019-01-28libgpg-error: use custom soname and symbol versionMichael Stahl
2018-05-04Removed executable permission on data filesAndrea Gelmini
2018-03-08Remove apparently unused external/libgpg-error/disable-rpath-option.patchStephan Bergmann
2018-03-08libgpg-error doesn't need RPATH at allStephan Bergmann
2017-12-11-Werror,-Wundef (clang-cl)Stephan Bergmann
2017-12-08fix fuzzer buildCaolán McNamara
2017-12-05tdf#114086: Fix macOS paths of external GPG librariesStephan Bergmann
2017-12-04gpg4libre: pass windows arch down to windresThorsten Behrens
2017-12-04gpg4libre: remove silly afxres.h / MFC dependency from gpgmeThorsten Behrens
2017-11-28Use Executable_cpp instead of default gcc as preprocessor for windresStephan Bergmann
2017-11-24gpg4libre: call libgpg-error subsystem initThorsten Behrens
2017-11-22gpg4libre: build libgpg-error natively on windowsThorsten Behrens
2017-10-26fix windows packagingThorsten Behrens
2017-10-26gpg4libre: enable OpenPGP support for MacThorsten Behrens
2017-08-15gpg4libre: update libgpg-error and gpgme to latestThorsten Behrens
2017-03-05gpg4libre: get rpath right for gpgmeThorsten Behrens
2017-02-17gpg4libre: fix build for older autoconf/automake versionsThorsten Behrens
2017-02-16gpg4libre: Build internal libgpg-error, libassuan and gpgme(pp)Katarina Behrens
2017-02-03gpg4libre: Download external gpgme and dependent libsKatarina Behrens