MCPcopy Create free account
hub / github.com/TeXworks/texworks / execute

Method execute

modules/QtPDF/src/PDFPageProcessingThread.cpp:207–220  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

205const QEvent::Type PDFLinksLoadedEvent::LinksLoadedEvent = static_cast<QEvent::Type>( QEvent::registerEventType() );
206
207bool PageProcessingRenderPageRequest::execute()
208{
209 // TODO: Aborting renders doesn't really work right now---the backend knows
210 // nothing about the PDF scenes.
211 //
212 // Idea: Perhaps allow page render requests to provide a pointer to a function
213 // that returns a `bool` value indicating if the request is still valid? Then
214 // the `PDFPageGraphicsItem` could have a function that indicates if the item
215 // is anywhere near a viewport.
216 QImage rendered_page = page->renderToImage(xres, yres, render_box, cache);
217 QCoreApplication::postEvent(listener, new PDFPageRenderedEvent(xres, yres, render_box, rendered_page));
218
219 return true;
220}
221
222bool PageProcessingLoadLinksRequest::execute()
223{

Callers 1

runMethod · 0.45

Calls 2

renderToImageMethod · 0.45
loadLinksMethod · 0.45

Tested by

no test coverage detected