mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-07-19 20:20:22 +08:00
Fix multiline Text Widget indentation
This commit is contained in:
committed by
Oleg Korshul
parent
87fa0f93be
commit
97d36fa1cd
@ -3643,7 +3643,7 @@ void CPdfWriter::DrawTextWidget(NSFonts::IApplicationFonts* pAppFonts, PdfWriter
|
||||
double dKoef = dFontSize / pFontTT->m_dUnitsPerEm;
|
||||
double dLineHeight = (pFontTT->m_dAscent + std::abs(pFontTT->m_dDescent)) * dKoef;
|
||||
|
||||
m_oLinesManager.CalculateLines(dFontSize, dWidth);
|
||||
m_oLinesManager.CalculateLines(dFontSize, dWidth - dShiftBorder * 4);
|
||||
|
||||
pTextWidget->StartAP();
|
||||
|
||||
@ -3852,7 +3852,7 @@ void CPdfWriter::DrawChoiceWidget(NSFonts::IApplicationFonts* pAppFonts, PdfWrit
|
||||
|
||||
m_oLinesManager.Init(pCodes2, pWidths, unLen, ushSpaceCode, ushNewLineCode, pFontTT->GetLineHeight(), pFontTT->GetAscent());
|
||||
|
||||
m_oLinesManager.CalculateLines(dFontSize, dWidth);
|
||||
m_oLinesManager.CalculateLines(dFontSize, dWidth - dShiftBorder * 4);
|
||||
|
||||
double dKoef = dFontSize / pFontTT->m_dUnitsPerEm;
|
||||
double dLineHeight = pFontTT->m_dHeight * dKoef;
|
||||
|
||||
@ -198,7 +198,7 @@ TEST_F(CPdfFileTest, GetMetaData)
|
||||
|
||||
TEST_F(CPdfFileTest, PdfType)
|
||||
{
|
||||
//GTEST_SKIP();
|
||||
GTEST_SKIP();
|
||||
|
||||
NSFile::CFileBinary oFile;
|
||||
ASSERT_TRUE(oFile.OpenFile(wsSrcFile));
|
||||
@ -234,7 +234,7 @@ TEST_F(CPdfFileTest, PdfType)
|
||||
|
||||
TEST_F(CPdfFileTest, GetEmbeddedFont)
|
||||
{
|
||||
//GTEST_SKIP();
|
||||
GTEST_SKIP();
|
||||
|
||||
LoadFromFile();
|
||||
|
||||
@ -378,7 +378,7 @@ TEST_F(CPdfFileTest, EditPdf)
|
||||
|
||||
TEST_F(CPdfFileTest, EditPdfFromBase64)
|
||||
{
|
||||
GTEST_SKIP();
|
||||
//GTEST_SKIP();
|
||||
|
||||
LoadFromFile();
|
||||
ASSERT_TRUE(pdfFile->EditPdf(wsDstFile));
|
||||
@ -410,7 +410,7 @@ TEST_F(CPdfFileTest, EditPdfFromBase64)
|
||||
EXPECT_TRUE(NSBase64::Base64Decode((const char*)pFileContent, dwFileSize, pBuffer, &nBufferLen));
|
||||
CConvertFromBinParams* pParams = new CConvertFromBinParams();
|
||||
pParams->m_sMediaDirectory = NSFile::GetProcessDirectory();
|
||||
pdfFile->AddToPdfFromBinary(pBuffer, nBufferLen, pParams);
|
||||
pdfFile->AddToPdfFromBinary(pBuffer + 4, nBufferLen - 4, pParams);
|
||||
|
||||
RELEASEOBJECT(pParams);
|
||||
RELEASEARRAYOBJECTS(pBuffer);
|
||||
|
||||
Reference in New Issue
Block a user