MCPcopy Create free account
hub / github.com/MayaPosch/NymphCast / get_image_size

Method get_image_size

player/NymphCastPlayer/container_qpainter.cpp:612–625  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

610}
611
612void DocumentContainerPrivate::get_image_size(const litehtml::tchar_t *src,
613 const litehtml::tchar_t *baseurl,
614 litehtml::size &sz)
615{
616 const auto qtSrc = QString::fromUtf8(src);
617 const auto qtBaseUrl = QString::fromUtf8(baseurl);
618 if (qtSrc.isEmpty()) // for some reason that happens
619 return;
620 qDebug(log) << "get_image_size:" << QString("src = \"%1\";").arg(qtSrc).toUtf8().constData()
621 << QString("base = \"%1\"").arg(qtBaseUrl).toUtf8().constData();
622 const QPixmap pm = getPixmap(qtSrc, qtBaseUrl);
623 sz.width = pm.width();
624 sz.height = pm.height();
625}
626
627void DocumentContainerPrivate::drawSelection(QPainter *painter, const QRect &clip) const
628{

Callers 5

init_background_paintMethod · 0.80
draw_list_markerMethod · 0.80
render_boxMethod · 0.80
get_content_sizeMethod · 0.80
renderMethod · 0.80

Calls 2

widthMethod · 0.45
heightMethod · 0.45

Tested by

no test coverage detected