[gnome-maps/wip/mlundblad/dont-use-offscreen-window] WIP: transitPrintLayout: Use Cairo and Pango to render
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-maps/wip/mlundblad/dont-use-offscreen-window] WIP: transitPrintLayout: Use Cairo and Pango to render
- Date: Sun, 17 Mar 2019 21:25:56 +0000 (UTC)
commit d0f4838506490bbba5e45c70f9869a39d4ea8fab
Author: Marcus Lundblad <ml update uu se>
Date: Sun Mar 17 22:22:29 2019 +0100
WIP: transitPrintLayout: Use Cairo and Pango to render
src/transitPrintLayout.js | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
---
diff --git a/src/transitPrintLayout.js b/src/transitPrintLayout.js
index 5648390..65ec005 100644
--- a/src/transitPrintLayout.js
+++ b/src/transitPrintLayout.js
@@ -220,8 +220,15 @@ class TransitPrintLayout extends PrintLayout.PrintLayout {
start: start,
print: true
});
+ let pageNum = this.numPages - 1;
+ let x = this._cursorX;
+ let y = this._cursorY;
+ let surface = new Cairo.ImageSurface(Cairo.Format.ARGB32, width, height);
+ let cr = new Cairo.Context(surface);
+
+ this._drawIcon(cr, leg.iconName, width, height);
- this._renderWidget(legRow, width, height);
+ this._addSurface(surface, x, y, pageNum);
}
_drawArrival(width, height) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]