diff options
author | Daniel Silva <danielfaleirosilva@gmail.com> | 2018-06-29 11:36:03 -0300 |
---|---|---|
committer | Aron Budea <aron.budea@collabora.com> | 2019-09-26 18:56:42 +0200 |
commit | 0d7fb10f8a0ecbaa154495a9a1993f6cade59328 (patch) | |
tree | d66f92f7427879dc705dfeca94652b8b3b2b57bd /i18nutil | |
parent | 344fbfe239b57063d23e585fbbf75a3a6b34987f (diff) |
Sets paper sizes listbox in print dialog
Change-Id: Iaeb50f6e854b90c1062d2ed6e3e053a6c26ea520
Reviewed-on: https://gerrit.libreoffice.org/56711
Tested-by: Jenkins
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
(cherry picked from commit ff4896a2af1df6138e9246fe1588dfe8c3748f1a)
Diffstat (limited to 'i18nutil')
-rw-r--r-- | i18nutil/source/utility/paper.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/i18nutil/source/utility/paper.cxx b/i18nutil/source/utility/paper.cxx index 9c1476c0dc03..07a8cc695adf 100644 --- a/i18nutil/source/utility/paper.cxx +++ b/i18nutil/source/utility/paper.cxx @@ -169,8 +169,11 @@ void PaperInfo::doSloppyFit() long lDiffW = labs(aDinTab[i].m_nWidth - m_nPaperWidth); long lDiffH = labs(aDinTab[i].m_nHeight - m_nPaperHeight); + long lFlipDiffW = labs(aDinTab[i].m_nHeight - m_nPaperWidth); + long lFlipDiffH = labs(aDinTab[i].m_nWidth - m_nPaperHeight); - if ( lDiffW < MAXSLOPPY && lDiffH < MAXSLOPPY ) + if ( (lDiffW < MAXSLOPPY && lDiffH < MAXSLOPPY) || + (lFlipDiffW < MAXSLOPPY && lFlipDiffH < MAXSLOPPY) ) { m_nPaperWidth = aDinTab[i].m_nWidth; m_nPaperHeight = aDinTab[i].m_nHeight; |