mirror of
https://github.com/JakubMelka/PDF4QT.git
synced 2025-06-05 21:59:17 +02:00
Settings of cache size
This commit is contained in:
@@ -17,11 +17,13 @@
|
||||
|
||||
#include "pdfdrawwidget.h"
|
||||
#include "pdfdrawspacecontroller.h"
|
||||
#include "pdfcompiler.h"
|
||||
|
||||
#include <QPainter>
|
||||
#include <QGridLayout>
|
||||
#include <QKeyEvent>
|
||||
#include <QApplication>
|
||||
#include <QPixmapCache>
|
||||
|
||||
namespace pdf
|
||||
{
|
||||
@@ -96,6 +98,13 @@ void PDFWidget::updateRenderer(RendererEngine engine, int samplesCount)
|
||||
updateRendererImpl();
|
||||
}
|
||||
|
||||
void PDFWidget::updateCacheLimits(int compiledPageCacheLimit, int thumbnailsCacheLimit, int fontCacheLimit, int instancedFontCacheLimit)
|
||||
{
|
||||
m_proxy->getCompiler()->setCacheLimit(compiledPageCacheLimit);
|
||||
QPixmapCache::setCacheLimit(thumbnailsCacheLimit);
|
||||
m_proxy->getFontCache()->setCacheLimits(fontCacheLimit, instancedFontCacheLimit);
|
||||
}
|
||||
|
||||
int PDFWidget::getPageRenderingErrorCount() const
|
||||
{
|
||||
int count = 0;
|
||||
|
||||
Reference in New Issue
Block a user