Hank Grabowski
Committed by David PHAM-VAN

Add demo app for all desktops and instructions for bootstrapping

Showing 96 changed files with 1781 additions and 226 deletions
@@ -94,6 +94,8 @@ test/pubspec.lock: test/pubspec.yaml @@ -94,6 +94,8 @@ test/pubspec.lock: test/pubspec.yaml
94 94
95 get: $(FONTS) pdf/pubspec.lock printing/pubspec.lock demo/pubspec.lock test/pubspec.lock 95 get: $(FONTS) pdf/pubspec.lock printing/pubspec.lock demo/pubspec.lock test/pubspec.lock
96 96
  97 +get-all: $(FONTS) demo/assets/logo.svg demo/assets/profile.jpg get
  98 +
97 test-pdf: svg $(FONTS) pdf/pubspec.lock .coverage 99 test-pdf: svg $(FONTS) pdf/pubspec.lock .coverage
98 cd pdf; $(DART_BIN) pub global run coverage:collect_coverage --port=$(COV_PORT) -o coverage.json --resume-isolates --wait-paused &\ 100 cd pdf; $(DART_BIN) pub global run coverage:collect_coverage --port=$(COV_PORT) -o coverage.json --resume-isolates --wait-paused &\
99 $(DART_BIN) --enable-asserts --disable-service-auth-codes --enable-vm-service=$(COV_PORT) --pause-isolates-on-exit test/all_tests.dart 101 $(DART_BIN) --enable-asserts --disable-service-auth-codes --enable-vm-service=$(COV_PORT) --pause-isolates-on-exit test/all_tests.dart
@@ -8,6 +8,7 @@ @@ -8,6 +8,7 @@
8 .buildlog/ 8 .buildlog/
9 .history 9 .history
10 .svn/ 10 .svn/
  11 +migrate_working_dir/
11 12
12 # IntelliJ related 13 # IntelliJ related
13 *.iml 14 *.iml
@@ -15,11 +16,14 @@ @@ -15,11 +16,14 @@
15 *.iws 16 *.iws
16 .idea/ 17 .idea/
17 18
18 -# Visual Studio Code related  
19 -.vscode/ 19 +# The .vscode folder contains launch configuration and tasks you configure in
  20 +# VS Code which you may wish to be included in version control, so this line
  21 +# is commented out by default.
  22 +#.vscode/
20 23
21 # Flutter/Dart/Pub related 24 # Flutter/Dart/Pub related
22 **/doc/api/ 25 **/doc/api/
  26 +**/ios/Flutter/.last_build_id
23 .dart_tool/ 27 .dart_tool/
24 .flutter-plugins 28 .flutter-plugins
25 .flutter-plugins-dependencies 29 .flutter-plugins-dependencies
@@ -27,18 +31,14 @@ @@ -27,18 +31,14 @@
27 .pub-cache/ 31 .pub-cache/
28 .pub/ 32 .pub/
29 /build/ 33 /build/
30 -.metadata  
31 34
32 -# Web related  
33 -lib/generated_plugin_registrant.dart 35 +# Symbolication related
  36 +app.*.symbols
34 37
35 -# Exceptions to above rules.  
36 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 38 +# Obfuscation related
  39 +app.*.map.json
37 40
38 -macos/Podfile.lock  
39 -assets/*.png  
40 -assets/*.jpg  
41 -assets/logo.svg  
42 -linux  
43 -  
44 -web/*.png 41 +# Android Studio will place build artifacts here
  42 +/android/app/debug
  43 +/android/app/profile
  44 +/android/app/release
1 # Pdf Printing Example 1 # Pdf Printing Example
2 2
  3 +This is a highly detailed example of the many features of the PDF library
  4 +embedded in a flutter application. This application shows among other things:
  5 +* How to embed the PDF render in your application
  6 +* How to enable printing, sharing, and saving PDFs from your application
  7 +* How to do full page layout and content generation including:
  8 + * Embedding fonts
  9 + * Embedding graphics
  10 + * Generating QR codes
  11 + * Using drawing primitives
  12 + * Generating charts and tables
  13 +
  14 +
  15 +### Instructions
  16 +The easiest way to run this on any of the
  17 +available Flutter target platforms is to check out the main project repository,
  18 +run the Makefile to get the needed assets, and then run the demo program.
  19 +Linux and macOS should be configured with Make already.
  20 +To get this working on Windows you will need to install GNU Make if it isn't already.
  21 +The easiest way to get this setup is to
  22 +install [The Chocolatey Software Manager](https://chocolatey.org/) and then
  23 +execute:
  24 +
  25 +```bash
  26 +choco install make
  27 +```
  28 +
  29 +With that installed the steps to get this running for your target platform
  30 +will be:
  31 +
  32 +Check out the source code from the repository:
  33 +```bash
  34 +git clone https://github.com/DavBfr/dart_pdf.git
  35 +```
  36 +
  37 +Navigate to the directory and install the font and graphics assets:
  38 +
  39 +```bash
  40 +cd dart_pdf
  41 +make get-all
  42 +```
  43 +
  44 +Next go into the demo source folder and run the program. Such as for Windows:
  45 +
  46 +```bash
  47 +flutter run -d windows
  48 +```
  49 +
  50 +...for Linux:
  51 +```bash
  52 +flutter run -d linux
  53 +```
  54 +
  55 +...for macOS:
  56 +```bash
  57 +flutter run -d macos
  58 +```
  59 +
  60 +
  61 +### Dart PDF Hello World
  62 +
3 ```dart 63 ```dart
4 import 'package:flutter/material.dart'; 64 import 'package:flutter/material.dart';
5 65
@@ -37,7 +37,7 @@ android { @@ -37,7 +37,7 @@ android {
37 defaultConfig { 37 defaultConfig {
38 // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 38 // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
39 applicationId "net.nfet.printing_demo" 39 applicationId "net.nfet.printing_demo"
40 - // You can update the following values to match your application needs. 40 + // You can update the following values to match your application needs.
41 // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration. 41 // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration.
42 minSdkVersion flutter.minSdkVersion 42 minSdkVersion flutter.minSdkVersion
43 targetSdkVersion flutter.targetSdkVersion 43 targetSdkVersion flutter.targetSdkVersion
1 <manifest xmlns:android="http://schemas.android.com/apk/res/android" 1 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
2 package="net.nfet.printing_demo"> 2 package="net.nfet.printing_demo">
3 <application 3 <application
4 - android:label="printing_demo" 4 + android:label="Pdf Printing Demo"
5 android:name="${applicationName}" 5 android:name="${applicationName}"
6 android:icon="@mipmap/ic_launcher"> 6 android:icon="@mipmap/ic_launcher">
7 <activity 7 <activity

544 Bytes | W: | H:

2.57 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

442 Bytes | W: | H:

1.72 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

721 Bytes | W: | H:

3.3 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

1.01 KB | W: | H:

5.03 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

1.41 KB | W: | H:

6.66 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
1 -#Fri Jun 23 08:50:38 CEST 2017  
2 distributionBase=GRADLE_USER_HOME 1 distributionBase=GRADLE_USER_HOME
3 distributionPath=wrapper/dists 2 distributionPath=wrapper/dists
4 zipStoreBase=GRADLE_USER_HOME 3 zipStoreBase=GRADLE_USER_HOME
  1 +<?xml version="1.0" encoding="utf-8"?>
  2 +<svg width="2500" height="2500" viewBox="0 0 256 256" preserveAspectRatio="xMinYMin meet" xmlns="http://www.w3.org/2000/svg">
  3 + <g transform="matrix(0.965512, 0, 0, 0.965512, 4.415424, 49.638378)" style="">
  4 + <path d="M 94.874 94.391 L 85.336 84.853 L 85.376 153.796 L 85.49 157.019 C 85.537 158.535 85.819 160.246 86.288 162.019 L 161.863 188.668 L 180.754 180.298 L 180.761 180.275 L 94.874 94.391" fill="#00D2B8" style=""/>
  5 + <path d="M 86.288 162.019 L 86.293 162.023 C 86.288 161.992 86.272 161.958 86.272 161.925 C 86.272 161.958 86.276 161.988 86.288 162.019 Z M 180.754 180.298 L 161.863 188.668 L 86.293 162.023 C 87.736 167.562 90.932 173.787 94.371 177.192 L 119.034 201.714 L 173.871 201.786 L 180.761 180.275 L 180.754 180.298 Z" fill="#55DDCA" style=""/>
  6 + <path d="M 55.963 129.22 C 53.521 131.827 54.734 137.204 58.666 141.165 L 75.624 158.264 L 86.288 162.019 C 85.819 160.246 85.537 158.535 85.49 157.019 L 85.376 153.796 L 85.336 84.853 L 55.963 129.22 Z" fill="#0081C6" style=""/>
  7 + <path d="M 162.483 85.738 C 160.71 85.285 159.009 85.005 157.468 84.957 L 154.062 84.839 L 85.336 84.848 L 180.77 180.275 L 180.778 180.275 L 189.16 161.365 L 162.483 85.738" fill="#0079B3" style=""/>
  8 + <path d="M 162.396 85.72 C 162.433 85.728 162.462 85.738 162.486 85.742 L 162.483 85.738 C 162.462 85.728 162.433 85.728 162.396 85.72 Z M 177.642 93.835 C 174.179 90.343 168.035 87.169 162.486 85.742 L 189.16 161.365 L 180.778 180.275 L 180.77 180.275 L 201.252 173.733 L 201.296 117.578 L 177.642 93.835 Z" fill="#00A4E4" style=""/>
  9 + <path d="M 158.746 75.139 L 141.652 58.17 C 137.699 54.254 132.32 53.035 129.72 55.47 L 85.336 84.848 L 154.062 84.839 L 157.468 84.957 C 159.009 85.005 160.71 85.285 162.483 85.738 L 158.746 75.139 Z" fill="#00D2B8" style=""/>
  10 + </g>
  11 + <rect x="62.204" y="24.701" width="132.822" height="65.295" style="fill: rgb(255, 255, 255);"/>
  12 + <path d="M 70.004 17.112 L 185.996 17.112 C 193.999 17.112 200.485 23.599 200.485 31.602 L 200.485 81.112 C 200.485 89.114 193.999 95.601 185.996 95.601 L 70.004 95.601 C 62.002 95.601 55.515 89.114 55.515 81.112 L 55.515 31.602 C 55.515 23.599 62.002 17.112 70.004 17.112 Z M 76.475 79.201 L 76.475 61.41 L 82.685 61.41 C 86.996 61.41 90.288 61.186 92.561 60.735 C 94.234 60.37 95.881 59.624 97.5 58.498 C 99.12 57.372 100.455 55.822 101.506 53.849 C 102.557 51.876 103.082 49.441 103.082 46.546 C 103.082 42.794 102.171 39.73 100.348 37.36 C 98.525 34.99 96.261 33.451 93.558 32.744 C 91.8 32.272 88.025 32.035 82.234 32.035 L 66.952 32.035 L 66.952 79.201 L 76.475 79.201 Z M 81.076 40.015 C 84.507 40.015 86.792 40.122 87.928 40.336 C 89.473 40.616 90.749 41.313 91.757 42.428 C 92.766 43.544 93.27 44.959 93.27 46.674 C 93.27 48.068 92.911 49.292 92.191 50.343 C 91.472 51.394 90.482 52.166 89.215 52.659 C 87.95 53.152 85.44 53.399 81.687 53.399 L 76.475 53.399 L 76.475 40.015 L 81.076 40.015 Z M 110.866 79.201 L 128.788 79.201 C 132.306 79.201 135.115 78.87 137.217 78.204 C 140.026 77.303 142.257 76.05 143.909 74.441 C 146.096 72.317 147.781 69.539 148.96 66.107 C 149.926 63.297 150.409 59.952 150.409 56.068 C 150.409 51.651 149.894 47.934 148.864 44.921 C 147.834 41.907 146.332 39.36 144.359 37.281 C 142.386 35.2 140.016 33.752 137.249 32.936 C 135.19 32.335 132.198 32.035 128.273 32.035 L 110.866 32.035 L 110.866 79.201 Z M 124.67 40.015 C 128.552 40.015 131.158 40.164 132.488 40.465 C 134.268 40.851 135.737 41.59 136.895 42.684 C 138.054 43.779 138.954 45.301 139.597 47.254 C 140.241 49.205 140.563 52.004 140.563 55.651 C 140.563 59.297 140.241 62.177 139.597 64.29 C 138.954 66.402 138.123 67.919 137.103 68.843 C 136.085 69.764 134.804 70.419 133.26 70.805 C 132.08 71.105 130.161 71.256 127.5 71.256 L 120.39 71.256 L 120.39 40.015 L 124.67 40.015 Z M 168.071 79.201 L 168.071 59.157 L 187.762 59.157 L 187.762 51.178 L 168.071 51.178 L 168.071 40.015 L 190.883 40.015 L 190.883 32.035 L 158.548 32.035 L 158.548 79.201 L 168.071 79.201 Z" style="fill: rgb(223, 3, 0);"/>
  13 +</svg>
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
  3 +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0" y="0" width="197.782" height="55.623" viewBox="0, 0, 197.782, 55.623">
  4 + <g id="Layer_1" transform="translate(-525.439, -128.094)">
  5 + <path d="M542.547,138.283 L542.586,137.529 L542.348,137.529 L542.072,138.283 L538.908,147.459 L541.834,147.459 z M531.156,157.9 L541.715,128.828 L546.936,128.828 L545.156,157.9 L541.004,157.9 L541.44,151.967 L537.326,151.967 L535.309,157.9 z" fill="#1E427B"/>
  6 + <path d="M564.654,128.828 L559.75,151.926 C559.433,153.113 558.959,154.182 558.367,155.09 C557.773,155.881 557.101,156.635 556.191,157.226 C555.242,157.9 554.095,158.217 552.711,158.217 C551.326,158.217 550.299,157.9 549.586,157.226 C548.914,156.635 548.558,155.881 548.4,155.09 C548.123,154.182 548.123,153.154 548.359,151.926 L553.263,128.828 L557.535,128.828 L552.631,151.926 C552.433,152.68 552.513,153.312 552.83,153.746 C552.988,153.945 553.224,154.062 553.58,154.062 C554.332,154.062 554.806,153.588 555.084,152.996 C555.203,152.758 555.361,152.4 555.478,151.926 L560.383,128.828 z" fill="#1E427B"/>
  7 + <path d="M564.82,133.22 L565.769,128.827 L578.109,128.827 L577.16,133.22 L573.127,133.22 L567.906,157.9 L563.634,157.9 L568.855,133.22 z" fill="#1E427B"/>
  8 + <path d="M584.94,134.802 C585.098,134.011 585.02,133.415 584.742,132.982 C584.585,132.782 584.307,132.665 583.952,132.665 C583.2,132.665 582.725,133.22 582.45,133.732 C582.292,134.048 582.172,134.406 582.091,134.802 L578.453,151.925 C578.255,152.679 578.336,153.312 578.653,153.745 C578.811,153.945 579.047,154.062 579.403,154.062 C580.155,154.062 580.629,153.587 580.906,152.995 C581.026,152.757 581.184,152.4 581.301,151.925 z M585.573,151.925 C585.255,153.113 584.781,154.181 584.19,155.089 C583.596,155.88 582.924,156.634 582.014,157.226 C581.065,157.9 579.919,158.216 578.534,158.216 C577.148,158.216 576.122,157.9 575.409,157.226 C574.737,156.634 574.38,155.88 574.223,155.089 C573.945,154.181 573.945,153.154 574.182,151.925 L577.82,134.802 C578.098,133.654 578.534,132.624 579.167,131.675 C579.76,130.884 580.393,130.093 581.301,129.501 C582.211,128.907 583.398,128.511 584.823,128.511 C586.247,128.511 587.234,128.907 587.906,129.501 C588.578,130.093 588.975,130.884 589.133,131.675 C589.411,132.546 589.411,133.573 589.211,134.802 z" fill="#1E427B"/>
  9 + <path d="M599.031,136.621 C599.23,135.672 599.426,134.603 599.308,133.773 C599.189,132.982 598.873,132.43 598.201,132.43 C597.093,132.467 596.5,133.615 596.144,135.314 C595.945,136.305 596.103,137.334 596.541,138.441 C596.974,139.549 597.49,140.693 598.082,141.922 C598.834,143.383 599.426,144.887 599.9,146.351 C600.338,147.812 600.533,149.316 600.179,150.898 C599.742,152.838 599.109,154.615 597.885,156.002 C596.658,157.385 595.076,158.217 592.703,158.217 C589.974,158.217 588.631,157.187 588.115,155.605 C587.523,154.023 587.84,151.967 588.273,149.752 L592.545,149.357 C592.269,150.582 592.07,151.809 592.189,152.717 C592.306,153.666 592.623,154.299 593.535,154.299 C594.801,154.299 595.511,152.955 595.945,151.098 C596.144,150.148 595.945,149.041 595.511,147.892 C595.392,147.617 595.275,147.301 595.154,147.021 C595.037,146.746 594.918,146.43 594.801,146.152 C594.521,145.56 594.205,144.928 593.888,144.254 C593.572,143.582 593.256,142.908 592.939,142.158 C592.269,140.656 591.912,139.152 591.795,137.65 C591.674,136.896 591.795,136.105 591.953,135.314 C592.269,133.732 592.98,132.033 594.205,130.726 C595.353,129.461 596.935,128.553 598.951,128.512 C601.603,128.475 602.828,129.541 603.344,131.084 C603.818,132.666 603.66,134.603 603.302,136.226 z" fill="#1E427B"/>
  10 + <path d="M609.065,141.922 C610.37,141.922 611.279,141.683 611.872,141.009 C612.503,140.376 612.82,139.31 613.177,137.687 C613.534,136.067 613.653,134.961 613.336,134.206 C613.02,133.536 612.229,133.179 610.922,133.179 z M607.599,128.827 L611.872,128.827 C613.732,128.827 615.473,129.265 616.617,130.648 C617.766,132.032 618.279,134.206 617.529,137.528 C616.776,140.851 615.393,142.987 613.692,144.372 C611.992,145.756 610.013,146.271 608.154,146.271 L605.702,157.9 L601.43,157.9 z" fill="#1E427B"/>
  11 + <path d="M621.232,128.828 L631.002,128.828 L630.052,133.221 L624.554,133.221 L622.933,140.851 L626.888,140.851 L625.898,145.519 L621.943,145.519 L620.244,153.508 L625.74,153.508 L624.832,157.9 L615.062,157.9 z" fill="#1E427B"/>
  12 + <path d="M633.322,128.828 L643.09,128.828 L642.14,133.221 L636.644,133.221 L635.021,140.851 L638.976,140.851 L637.99,145.519 L634.035,145.519 L632.332,153.508 L637.832,153.508 L636.92,157.9 L627.152,157.9 z" fill="#1E427B"/>
  13 + <path d="M644.383,153.629 C645.848,153.629 646.717,153.47 647.467,152.047 C648.141,150.739 648.696,148.407 649.09,146.509 C649.287,145.597 649.487,144.53 649.762,143.345 C649.998,142.157 650.237,141.089 650.436,140.14 C650.83,138.282 651.305,136.067 651.147,134.644 C651.028,133.257 650.237,133.099 648.774,133.099 z M639.24,157.899 L645.41,128.827 L648.774,128.827 C652.729,128.827 654.627,129.618 655.377,131.834 C656.01,134.048 655.418,137.649 654.192,143.382 C652.967,149.077 652.055,152.679 650.473,154.894 C648.854,157.108 646.559,157.899 642.604,157.899 z" fill="#1E427B"/>
  14 + <path d="M530.932,173.17 C531.024,172.707 531.123,172.19 531.063,171.78 C531.004,171.399 530.852,171.125 530.524,171.125 C529.983,171.144 529.692,171.7 529.522,172.532 C529.422,173.019 529.5,173.521 529.711,174.054 C529.926,174.601 530.174,175.161 530.465,175.754 C530.834,176.474 531.123,177.213 531.354,177.923 C531.569,178.636 531.662,179.37 531.491,180.142 C531.274,181.088 530.971,181.959 530.371,182.633 C529.768,183.308 528.998,183.716 527.84,183.716 C526.506,183.716 525.85,183.213 525.598,182.439 C525.309,181.668 525.461,180.657 525.676,179.586 L527.76,179.388 C527.629,179.985 527.53,180.588 527.59,181.032 C527.649,181.489 527.801,181.802 528.246,181.802 C528.862,181.802 529.211,181.146 529.422,180.235 C529.522,179.774 529.422,179.233 529.211,178.677 C529.153,178.538 529.094,178.386 529.037,178.245 C528.977,178.114 528.92,177.964 528.862,177.823 C528.725,177.534 528.573,177.23 528.42,176.898 C528.264,176.567 528.106,176.241 527.952,175.873 C527.629,175.144 527.455,174.407 527.395,173.67 C527.336,173.3 527.395,172.92 527.473,172.532 C527.629,171.759 527.971,170.927 528.573,170.293 C529.135,169.677 529.909,169.228 530.893,169.211 C532.184,169.187 532.786,169.714 533.034,170.468 C533.266,171.241 533.19,172.19 533.014,172.981 z" fill="#DD4044"/>
  15 + <path d="M537.373,173.984 L537.391,173.616 L537.279,173.616 L537.141,173.984 L535.598,178.466 L537.027,178.466 z M531.809,183.558 L536.965,169.369 L539.518,169.369 L538.648,183.558 L536.619,183.558 L536.83,180.658 L534.82,180.658 L533.84,183.558 z" fill="#DD4044"/>
  16 + <path d="M543.631,183.558 L544.194,174.642 L544.235,174.037 L544.115,174.037 L542.108,183.558 L540.174,183.558 L543.192,169.369 L545.736,169.369 L545.584,175.855 L545.526,176.605 L545.565,176.605 L545.817,175.855 L548.44,169.369 L550.99,169.369 L547.979,183.558 L546.047,183.558 L548.057,174.037 L547.944,174.037 L547.744,174.642 L544.52,183.558 z" fill="#DD4044"/>
  17 + <path d="M553.283,169.369 L558.051,169.369 L557.594,171.508 L554.906,171.508 L554.115,175.238 L556.047,175.238 L555.566,177.517 L553.633,177.517 L552.803,181.42 L555.486,181.42 L555.039,183.558 L550.271,183.558 z" fill="#DD4044"/>
  18 + <path d="M562.664,181.472 C563.383,181.472 563.805,181.396 564.174,180.699 C564.496,180.066 564.769,178.925 564.965,178.003 C565.059,177.554 565.156,177.033 565.287,176.452 C565.406,175.872 565.521,175.355 565.621,174.882 C565.814,173.984 566.045,172.902 565.967,172.208 C565.908,171.531 565.521,171.454 564.809,171.454 z M560.154,183.558 L563.17,169.368 L564.809,169.368 C566.738,169.368 567.668,169.755 568.035,170.831 C568.34,171.915 568.053,173.669 567.457,176.474 C566.857,179.257 566.412,181.011 565.639,182.095 C564.848,183.171 563.725,183.558 561.795,183.558 z" fill="#DD4044"/>
  19 + <path d="M572.82,173.984 L572.838,173.616 L572.722,173.616 L572.584,173.984 L571.043,178.466 L572.472,178.466 z M567.257,183.558 L572.414,169.369 L574.965,169.369 L574.093,183.558 L572.068,183.558 L572.283,180.658 L570.267,180.658 L569.283,183.558 z" fill="#DD4044"/>
  20 + <path d="M579.645,173.908 L579.666,174.037 L579.704,174.037 L579.803,173.908 L581.812,169.369 L583.858,169.369 L579.997,177.517 L578.723,183.558 L576.635,183.558 L577.911,177.517 L577.528,169.369 L579.573,169.369 z" fill="#DD4044"/>
  21 + <path d="M590.693,173.984 L590.713,173.616 L590.595,173.616 L590.459,173.984 L588.918,178.466 L590.343,178.466 z M585.129,183.558 L590.283,169.369 L592.834,169.369 L591.964,183.558 L589.941,183.558 L590.152,180.658 L588.14,180.658 L587.154,183.558 z" fill="#DD4044"/>
  22 + <path d="M601.986,169.369 L599.591,180.64 C599.437,181.226 599.203,181.748 598.92,182.187 C598.625,182.58 598.298,182.949 597.855,183.23 C597.39,183.558 596.83,183.717 596.154,183.717 C595.478,183.717 594.976,183.558 594.627,183.23 C594.298,182.949 594.127,182.58 594.047,182.187 C593.916,181.748 593.916,181.246 594.027,180.64 L596.427,169.369 L598.509,169.369 L596.115,180.64 C596.019,181.012 596.054,181.326 596.213,181.527 C596.289,181.631 596.408,181.685 596.578,181.685 C596.945,181.685 597.179,181.449 597.31,181.168 C597.369,181.051 597.449,180.877 597.502,180.64 L599.9,169.369 z" fill="#DD4044"/>
  23 + <path d="M602.565,171.507 L603.034,169.368 L609.057,169.368 L608.591,171.507 L606.625,171.507 L604.075,183.558 L601.987,183.558 L604.539,171.507 z" fill="#DD4044"/>
  24 + <path d="M612.889,172.287 C612.967,171.894 612.926,171.601 612.795,171.4 C612.715,171.297 612.584,171.242 612.41,171.242 C612.045,171.242 611.813,171.508 611.676,171.76 C611.598,171.916 611.541,172.088 611.5,172.287 L609.725,180.641 C609.625,181.012 609.664,181.326 609.819,181.527 C609.897,181.631 610.014,181.685 610.192,181.685 C610.553,181.685 610.789,181.449 610.922,181.168 C610.983,181.051 611.055,180.877 611.114,180.641 z M613.202,180.641 C613.047,181.226 612.815,181.748 612.526,182.187 C612.235,182.58 611.905,182.949 611.461,183.23 C611.002,183.558 610.436,183.717 609.762,183.717 C609.088,183.717 608.582,183.558 608.237,183.23 C607.91,182.949 607.733,182.58 607.66,182.187 C607.522,181.748 607.522,181.246 607.641,180.641 L609.414,172.287 C609.551,171.719 609.762,171.219 610.073,170.752 C610.364,170.371 610.67,169.978 611.114,169.697 C611.559,169.404 612.135,169.211 612.836,169.211 C613.528,169.211 614.01,169.404 614.338,169.697 C614.666,169.978 614.864,170.371 614.938,170.752 C615.077,171.18 615.077,171.682 614.977,172.287 z" fill="#DD4044"/>
  25 + <path d="M621.674,175.754 C622.313,175.754 622.756,175.645 623.049,175.315 C623.356,175.004 623.506,174.484 623.682,173.693 C623.858,172.902 623.916,172.361 623.762,171.992 C623.606,171.664 623.225,171.49 622.584,171.49 z M620.963,169.369 L623.049,169.369 C623.955,169.369 624.807,169.58 625.362,170.254 C625.926,170.928 626.174,171.992 625.809,173.616 C625.44,175.238 624.766,176.281 623.936,176.955 C623.104,177.635 622.141,177.887 621.231,177.887 L620.033,183.559 L617.947,183.559 z" fill="#DD4044"/>
  26 + <path d="M629.947,173.984 L629.967,173.616 L629.851,173.616 L629.711,173.984 L628.17,178.466 L629.597,178.466 z M624.384,183.558 L629.537,169.369 L632.09,169.369 L631.218,183.558 L629.195,183.558 L629.406,180.658 L627.396,180.658 L626.412,183.558 z" fill="#DD4044"/>
  27 + <path d="M636.514,175.644 C636.809,175.644 637.192,175.621 637.561,175.331 C637.922,175.04 638.291,174.54 638.502,173.537 C638.713,172.533 638.582,172.009 638.332,171.718 C638.078,171.437 637.692,171.437 637.407,171.437 z M636.475,183.558 L636.651,177.572 L636.092,177.572 L634.836,183.558 L632.748,183.558 L635.764,169.369 L637.85,169.369 C640.336,169.369 641.094,170.751 640.532,173.458 C640.223,174.865 639.584,176.146 638.676,176.685 L638.563,183.558 z" fill="#DD4044"/>
  28 + <path d="M641.734,171.507 L642.201,169.368 L648.226,169.368 L647.763,171.507 L645.795,171.507 L643.242,183.558 L641.16,183.558 L643.711,171.507 z" fill="#DD4044"/>
  29 + <path d="M651.838,173.17 C651.93,172.707 652.029,172.19 651.971,171.78 C651.912,171.399 651.76,171.125 651.43,171.125 C650.889,171.144 650.6,171.7 650.428,172.532 C650.33,173.019 650.408,173.521 650.619,174.054 C650.832,174.601 651.08,175.161 651.369,175.754 C651.738,176.474 652.029,177.213 652.26,177.923 C652.475,178.636 652.57,179.37 652.397,180.142 C652.182,181.088 651.877,181.959 651.279,182.633 C650.674,183.308 649.904,183.716 648.748,183.716 C647.412,183.716 646.756,183.213 646.506,182.439 C646.217,181.668 646.367,180.657 646.582,179.586 L648.668,179.388 C648.537,179.985 648.438,180.588 648.496,181.032 C648.555,181.489 648.707,181.802 649.152,181.802 C649.768,181.802 650.119,181.146 650.33,180.235 C650.428,179.774 650.33,179.233 650.119,178.677 C650.059,178.538 650.002,178.386 649.943,178.245 C649.883,178.114 649.828,177.964 649.768,177.823 C649.629,177.534 649.479,177.23 649.328,176.898 C649.17,176.567 649.012,176.241 648.859,175.873 C648.537,175.144 648.361,174.407 648.301,173.67 C648.244,173.3 648.301,172.92 648.379,172.532 C648.537,171.759 648.879,170.927 649.479,170.293 C650.041,169.677 650.815,169.228 651.799,169.211 C653.09,169.187 653.69,169.714 653.942,170.468 C654.172,171.241 654.098,172.19 653.922,172.981 z" fill="#DD4044"/>
  30 + <path d="M679.41,163.351 C679.41,164.228 680.121,164.933 680.992,164.933 L694.031,164.933 C694.902,164.933 695.613,164.228 695.613,163.351 C695.613,162.478 694.902,161.769 694.031,161.769 L680.992,161.769 C680.121,161.769 679.41,162.478 679.41,163.351" fill="#E21D34"/>
  31 + <path d="M706.387,170.599 C709.498,170.593 712.018,168.078 712.03,164.956 C712.018,161.845 709.498,159.324 706.387,159.324 C703.268,159.324 700.75,161.845 700.744,164.956 C700.75,168.078 703.268,170.593 706.387,170.599 M697.58,164.956 L697.58,164.956 C697.58,160.099 701.52,156.16 706.387,156.16 C711.248,156.16 715.194,160.091 715.194,164.956 C715.194,169.82 711.248,173.763 706.387,173.763 C701.52,173.763 697.58,169.82 697.58,164.956" fill="#E21D34"/>
  32 + <path d="M668.635,170.599 C671.752,170.593 674.272,168.078 674.278,164.956 C674.272,161.845 671.752,159.324 668.635,159.324 C665.524,159.324 663.004,161.845 662.996,164.956 C663.004,168.078 665.524,170.593 668.635,170.599 M659.832,164.956 L659.832,164.956 C659.832,160.091 663.778,156.16 668.635,156.16 C673.498,156.16 677.442,160.091 677.442,164.956 C677.442,169.82 673.498,173.763 668.635,173.763 C663.778,173.763 659.832,169.82 659.832,164.956" fill="#E21D34"/>
  33 + <path d="M722.617,157.539 C722.26,156.805 721.785,156.056 721.189,155.301 C720.006,153.781 718.388,152.205 716.471,150.754 L694.517,134.143 C692.224,132.406 689.154,130.937 685.935,129.853 C682.715,128.775 679.379,128.096 676.5,128.094 L664.902,128.094 C663.875,128.09 662.873,128.424 662.142,129.107 C661.396,129.777 660.994,130.779 660.996,131.773 C660.996,132.246 661.08,132.719 661.234,133.176 L666.138,148.012 C666.199,148.174 666.215,148.305 666.215,148.408 C666.209,148.62 666.16,148.725 666.019,148.883 C665.879,149.035 665.596,149.217 665.154,149.312 C659.002,150.678 654.191,155.564 652.931,161.752 L529.599,161.752 C528.73,161.752 528.017,162.465 528.017,163.334 C528.017,164.219 528.73,164.926 529.599,164.926 L654.105,164.926 C654.976,165.019 655.758,164.398 655.855,163.527 C656.459,158.033 660.543,153.576 665.844,152.4 C666.789,152.195 667.652,151.76 668.312,151.07 C668.976,150.385 669.381,149.412 669.379,148.408 C669.379,147.945 669.299,147.471 669.144,147.014 L664.24,132.184 C664.181,132.01 664.16,131.875 664.16,131.773 C664.172,131.559 664.222,131.506 664.283,131.43 C664.357,131.365 664.515,131.26 664.902,131.258 L676.5,131.258 C678.871,131.254 681.971,131.851 684.924,132.853 C687.888,133.844 690.724,135.232 692.607,136.66 L714.566,153.271 C717.14,155.205 719.096,157.478 719.769,158.904 C719.992,159.361 720.062,159.719 720.056,159.816 L718.474,162.56 C718.041,163.316 718.297,164.283 719.056,164.721 C719.306,164.863 719.576,164.934 719.846,164.934 C720.392,164.934 720.92,164.652 721.215,164.143 L722.836,161.336 C723.121,160.844 723.221,160.31 723.221,159.828 C723.215,159.01 722.972,158.281 722.617,157.539" fill="#E21D34"/>
  34 + </g>
  35 +</svg>
  1 +**/dgph
1 *.mode1v3 2 *.mode1v3
2 *.mode2v3 3 *.mode2v3
3 *.moved-aside 4 *.moved-aside
@@ -18,6 +19,7 @@ Flutter/App.framework @@ -18,6 +19,7 @@ Flutter/App.framework
18 Flutter/Flutter.framework 19 Flutter/Flutter.framework
19 Flutter/Flutter.podspec 20 Flutter/Flutter.podspec
20 Flutter/Generated.xcconfig 21 Flutter/Generated.xcconfig
  22 +Flutter/ephemeral/
21 Flutter/app.flx 23 Flutter/app.flx
22 Flutter/app.zip 24 Flutter/app.zip
23 Flutter/flutter_assets/ 25 Flutter/flutter_assets/
@@ -21,6 +21,6 @@ @@ -21,6 +21,6 @@
21 <key>CFBundleVersion</key> 21 <key>CFBundleVersion</key>
22 <string>1.0</string> 22 <string>1.0</string>
23 <key>MinimumOSVersion</key> 23 <key>MinimumOSVersion</key>
24 - <string>8.0</string> 24 + <string>11.0</string>
25 </dict> 25 </dict>
26 </plist> 26 </plist>
1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"  
3 #include "Generated.xcconfig" 2 #include "Generated.xcconfig"
1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"  
3 #include "Generated.xcconfig" 2 #include "Generated.xcconfig"
1 # Uncomment this line to define a global platform for your project 1 # Uncomment this line to define a global platform for your project
2 -# platform :ios, '9.0' 2 +# platform :ios, '11.0'
3 3
4 # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 4 # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
5 ENV['COCOAPODS_DISABLE_STATS'] = 'true' 5 ENV['COCOAPODS_DISABLE_STATS'] = 'true'
@@ -3,13 +3,13 @@ @@ -3,13 +3,13 @@
3 archiveVersion = 1; 3 archiveVersion = 1;
4 classes = { 4 classes = {
5 }; 5 };
6 - objectVersion = 46; 6 + objectVersion = 50;
7 objects = { 7 objects = {
8 8
9 /* Begin PBXBuildFile section */ 9 /* Begin PBXBuildFile section */
10 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 10 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
11 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 11 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
12 - 54041616FF56C1C2938DCC0B /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B649BF314565B7A4BC98B168 /* Pods_Runner.framework */; }; 12 + 5FF333BE56E4DF3BED20B051 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DC8A3041B56DB9EF0868092D /* Pods_Runner.framework */; };
13 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 13 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
14 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 14 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
15 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 15 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
@@ -32,11 +32,12 @@ @@ -32,11 +32,12 @@
32 /* Begin PBXFileReference section */ 32 /* Begin PBXFileReference section */
33 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; }; 33 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; };
34 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; }; 34 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
  35 + 1575CE4362E88CBACD2B8DA2 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
35 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; }; 36 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
36 - 4AC5914B4F011A1A678B8063 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };  
37 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; }; 37 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
38 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; }; 38 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
39 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; }; 39 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
  40 + 89D208F761AB8EDBA7A12642 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
40 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; }; 41 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; };
41 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; }; 42 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; };
42 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 43 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
@@ -44,9 +45,8 @@ @@ -44,9 +45,8 @@
44 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; }; 45 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
45 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; 46 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
46 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; 47 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
47 - 9F463DE4D92BD02EFE020E7F /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };  
48 - B07B8E900764710FEB6A5F77 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };  
49 - B649BF314565B7A4BC98B168 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 48 + DC8A3041B56DB9EF0868092D /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
  49 + F2FF7D933510B9B8E55E2004 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
50 /* End PBXFileReference section */ 50 /* End PBXFileReference section */
51 51
52 /* Begin PBXFrameworksBuildPhase section */ 52 /* Begin PBXFrameworksBuildPhase section */
@@ -54,24 +54,13 @@ @@ -54,24 +54,13 @@
54 isa = PBXFrameworksBuildPhase; 54 isa = PBXFrameworksBuildPhase;
55 buildActionMask = 2147483647; 55 buildActionMask = 2147483647;
56 files = ( 56 files = (
57 - 54041616FF56C1C2938DCC0B /* Pods_Runner.framework in Frameworks */, 57 + 5FF333BE56E4DF3BED20B051 /* Pods_Runner.framework in Frameworks */,
58 ); 58 );
59 runOnlyForDeploymentPostprocessing = 0; 59 runOnlyForDeploymentPostprocessing = 0;
60 }; 60 };
61 /* End PBXFrameworksBuildPhase section */ 61 /* End PBXFrameworksBuildPhase section */
62 62
63 /* Begin PBXGroup section */ 63 /* Begin PBXGroup section */
64 - 425553110560F7A9BCF22DF3 /* Pods */ = {  
65 - isa = PBXGroup;  
66 - children = (  
67 - 4AC5914B4F011A1A678B8063 /* Pods-Runner.debug.xcconfig */,  
68 - 9F463DE4D92BD02EFE020E7F /* Pods-Runner.release.xcconfig */,  
69 - B07B8E900764710FEB6A5F77 /* Pods-Runner.profile.xcconfig */,  
70 - );  
71 - name = Pods;  
72 - path = Pods;  
73 - sourceTree = "<group>";  
74 - };  
75 9740EEB11CF90186004384FC /* Flutter */ = { 64 9740EEB11CF90186004384FC /* Flutter */ = {
76 isa = PBXGroup; 65 isa = PBXGroup;
77 children = ( 66 children = (
@@ -89,8 +78,8 @@ @@ -89,8 +78,8 @@
89 9740EEB11CF90186004384FC /* Flutter */, 78 9740EEB11CF90186004384FC /* Flutter */,
90 97C146F01CF9000F007C117D /* Runner */, 79 97C146F01CF9000F007C117D /* Runner */,
91 97C146EF1CF9000F007C117D /* Products */, 80 97C146EF1CF9000F007C117D /* Products */,
92 - 425553110560F7A9BCF22DF3 /* Pods */,  
93 - FDE4CFBBC76DEA5CE219DBFB /* Frameworks */, 81 + B6C4036C575362F7E034F867 /* Pods */,
  82 + D2A81FFB6EC6F5BCCCCC06D0 /* Frameworks */,
94 ); 83 );
95 sourceTree = "<group>"; 84 sourceTree = "<group>";
96 }; 85 };
@@ -117,10 +106,21 @@ @@ -117,10 +106,21 @@
117 path = Runner; 106 path = Runner;
118 sourceTree = "<group>"; 107 sourceTree = "<group>";
119 }; 108 };
120 - FDE4CFBBC76DEA5CE219DBFB /* Frameworks */ = { 109 + B6C4036C575362F7E034F867 /* Pods */ = {
  110 + isa = PBXGroup;
  111 + children = (
  112 + F2FF7D933510B9B8E55E2004 /* Pods-Runner.debug.xcconfig */,
  113 + 89D208F761AB8EDBA7A12642 /* Pods-Runner.release.xcconfig */,
  114 + 1575CE4362E88CBACD2B8DA2 /* Pods-Runner.profile.xcconfig */,
  115 + );
  116 + name = Pods;
  117 + path = Pods;
  118 + sourceTree = "<group>";
  119 + };
  120 + D2A81FFB6EC6F5BCCCCC06D0 /* Frameworks */ = {
121 isa = PBXGroup; 121 isa = PBXGroup;
122 children = ( 122 children = (
123 - B649BF314565B7A4BC98B168 /* Pods_Runner.framework */, 123 + DC8A3041B56DB9EF0868092D /* Pods_Runner.framework */,
124 ); 124 );
125 name = Frameworks; 125 name = Frameworks;
126 sourceTree = "<group>"; 126 sourceTree = "<group>";
@@ -132,14 +132,14 @@ @@ -132,14 +132,14 @@
132 isa = PBXNativeTarget; 132 isa = PBXNativeTarget;
133 buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 133 buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
134 buildPhases = ( 134 buildPhases = (
135 - CD6EAF941BD812B0ACE8E6DD /* [CP] Check Pods Manifest.lock */, 135 + CDA7C9A2E458F0AF9A6B22C4 /* [CP] Check Pods Manifest.lock */,
136 9740EEB61CF901F6004384FC /* Run Script */, 136 9740EEB61CF901F6004384FC /* Run Script */,
137 97C146EA1CF9000F007C117D /* Sources */, 137 97C146EA1CF9000F007C117D /* Sources */,
138 97C146EB1CF9000F007C117D /* Frameworks */, 138 97C146EB1CF9000F007C117D /* Frameworks */,
139 97C146EC1CF9000F007C117D /* Resources */, 139 97C146EC1CF9000F007C117D /* Resources */,
140 9705A1C41CF9048500538489 /* Embed Frameworks */, 140 9705A1C41CF9048500538489 /* Embed Frameworks */,
141 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 141 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
142 - 6766C503D8DE859AA07A0125 /* [CP] Embed Pods Frameworks */, 142 + E6E9CB8EF2EDFB7B3BBDBB32 /* [CP] Embed Pods Frameworks */,
143 ); 143 );
144 buildRules = ( 144 buildRules = (
145 ); 145 );
@@ -156,7 +156,7 @@ @@ -156,7 +156,7 @@
156 97C146E61CF9000F007C117D /* Project object */ = { 156 97C146E61CF9000F007C117D /* Project object */ = {
157 isa = PBXProject; 157 isa = PBXProject;
158 attributes = { 158 attributes = {
159 - LastUpgradeCheck = 1020; 159 + LastUpgradeCheck = 1300;
160 ORGANIZATIONNAME = ""; 160 ORGANIZATIONNAME = "";
161 TargetAttributes = { 161 TargetAttributes = {
162 97C146ED1CF9000F007C117D = { 162 97C146ED1CF9000F007C117D = {
@@ -212,23 +212,6 @@ @@ -212,23 +212,6 @@
212 shellPath = /bin/sh; 212 shellPath = /bin/sh;
213 shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; 213 shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
214 }; 214 };
215 - 6766C503D8DE859AA07A0125 /* [CP] Embed Pods Frameworks */ = {  
216 - isa = PBXShellScriptBuildPhase;  
217 - buildActionMask = 2147483647;  
218 - files = (  
219 - );  
220 - inputFileListPaths = (  
221 - "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",  
222 - );  
223 - name = "[CP] Embed Pods Frameworks";  
224 - outputFileListPaths = (  
225 - "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",  
226 - );  
227 - runOnlyForDeploymentPostprocessing = 0;  
228 - shellPath = /bin/sh;  
229 - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";  
230 - showEnvVarsInLog = 0;  
231 - };  
232 9740EEB61CF901F6004384FC /* Run Script */ = { 215 9740EEB61CF901F6004384FC /* Run Script */ = {
233 isa = PBXShellScriptBuildPhase; 216 isa = PBXShellScriptBuildPhase;
234 buildActionMask = 2147483647; 217 buildActionMask = 2147483647;
@@ -243,7 +226,7 @@ @@ -243,7 +226,7 @@
243 shellPath = /bin/sh; 226 shellPath = /bin/sh;
244 shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 227 shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
245 }; 228 };
246 - CD6EAF941BD812B0ACE8E6DD /* [CP] Check Pods Manifest.lock */ = { 229 + CDA7C9A2E458F0AF9A6B22C4 /* [CP] Check Pods Manifest.lock */ = {
247 isa = PBXShellScriptBuildPhase; 230 isa = PBXShellScriptBuildPhase;
248 buildActionMask = 2147483647; 231 buildActionMask = 2147483647;
249 files = ( 232 files = (
@@ -265,6 +248,23 @@ @@ -265,6 +248,23 @@
265 shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 248 shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
266 showEnvVarsInLog = 0; 249 showEnvVarsInLog = 0;
267 }; 250 };
  251 + E6E9CB8EF2EDFB7B3BBDBB32 /* [CP] Embed Pods Frameworks */ = {
  252 + isa = PBXShellScriptBuildPhase;
  253 + buildActionMask = 2147483647;
  254 + files = (
  255 + );
  256 + inputFileListPaths = (
  257 + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
  258 + );
  259 + name = "[CP] Embed Pods Frameworks";
  260 + outputFileListPaths = (
  261 + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
  262 + );
  263 + runOnlyForDeploymentPostprocessing = 0;
  264 + shellPath = /bin/sh;
  265 + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
  266 + showEnvVarsInLog = 0;
  267 + };
268 /* End PBXShellScriptBuildPhase section */ 268 /* End PBXShellScriptBuildPhase section */
269 269
270 /* Begin PBXSourcesBuildPhase section */ 270 /* Begin PBXSourcesBuildPhase section */
@@ -340,7 +340,7 @@ @@ -340,7 +340,7 @@
340 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 340 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
341 GCC_WARN_UNUSED_FUNCTION = YES; 341 GCC_WARN_UNUSED_FUNCTION = YES;
342 GCC_WARN_UNUSED_VARIABLE = YES; 342 GCC_WARN_UNUSED_VARIABLE = YES;
343 - IPHONEOS_DEPLOYMENT_TARGET = 9.0; 343 + IPHONEOS_DEPLOYMENT_TARGET = 11.0;
344 MTL_ENABLE_DEBUG_INFO = NO; 344 MTL_ENABLE_DEBUG_INFO = NO;
345 SDKROOT = iphoneos; 345 SDKROOT = iphoneos;
346 SUPPORTED_PLATFORMS = iphoneos; 346 SUPPORTED_PLATFORMS = iphoneos;
@@ -356,9 +356,13 @@ @@ -356,9 +356,13 @@
356 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 356 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
357 CLANG_ENABLE_MODULES = YES; 357 CLANG_ENABLE_MODULES = YES;
358 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 358 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
  359 + DEVELOPMENT_TEAM = EC2XFC58R3;
359 ENABLE_BITCODE = NO; 360 ENABLE_BITCODE = NO;
360 INFOPLIST_FILE = Runner/Info.plist; 361 INFOPLIST_FILE = Runner/Info.plist;
361 - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 362 + LD_RUNPATH_SEARCH_PATHS = (
  363 + "$(inherited)",
  364 + "@executable_path/Frameworks",
  365 + );
362 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo; 366 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo;
363 PRODUCT_NAME = "$(TARGET_NAME)"; 367 PRODUCT_NAME = "$(TARGET_NAME)";
364 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 368 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
@@ -414,7 +418,7 @@ @@ -414,7 +418,7 @@
414 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 418 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
415 GCC_WARN_UNUSED_FUNCTION = YES; 419 GCC_WARN_UNUSED_FUNCTION = YES;
416 GCC_WARN_UNUSED_VARIABLE = YES; 420 GCC_WARN_UNUSED_VARIABLE = YES;
417 - IPHONEOS_DEPLOYMENT_TARGET = 9.0; 421 + IPHONEOS_DEPLOYMENT_TARGET = 11.0;
418 MTL_ENABLE_DEBUG_INFO = YES; 422 MTL_ENABLE_DEBUG_INFO = YES;
419 ONLY_ACTIVE_ARCH = YES; 423 ONLY_ACTIVE_ARCH = YES;
420 SDKROOT = iphoneos; 424 SDKROOT = iphoneos;
@@ -463,11 +467,12 @@ @@ -463,11 +467,12 @@
463 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 467 GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
464 GCC_WARN_UNUSED_FUNCTION = YES; 468 GCC_WARN_UNUSED_FUNCTION = YES;
465 GCC_WARN_UNUSED_VARIABLE = YES; 469 GCC_WARN_UNUSED_VARIABLE = YES;
466 - IPHONEOS_DEPLOYMENT_TARGET = 9.0; 470 + IPHONEOS_DEPLOYMENT_TARGET = 11.0;
467 MTL_ENABLE_DEBUG_INFO = NO; 471 MTL_ENABLE_DEBUG_INFO = NO;
468 SDKROOT = iphoneos; 472 SDKROOT = iphoneos;
469 SUPPORTED_PLATFORMS = iphoneos; 473 SUPPORTED_PLATFORMS = iphoneos;
470 - SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 474 + SWIFT_COMPILATION_MODE = wholemodule;
  475 + SWIFT_OPTIMIZATION_LEVEL = "-O";
471 TARGETED_DEVICE_FAMILY = "1,2"; 476 TARGETED_DEVICE_FAMILY = "1,2";
472 VALIDATE_PRODUCT = YES; 477 VALIDATE_PRODUCT = YES;
473 }; 478 };
@@ -480,9 +485,13 @@ @@ -480,9 +485,13 @@
480 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 485 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
481 CLANG_ENABLE_MODULES = YES; 486 CLANG_ENABLE_MODULES = YES;
482 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 487 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
  488 + DEVELOPMENT_TEAM = EC2XFC58R3;
483 ENABLE_BITCODE = NO; 489 ENABLE_BITCODE = NO;
484 INFOPLIST_FILE = Runner/Info.plist; 490 INFOPLIST_FILE = Runner/Info.plist;
485 - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 491 + LD_RUNPATH_SEARCH_PATHS = (
  492 + "$(inherited)",
  493 + "@executable_path/Frameworks",
  494 + );
486 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo; 495 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo;
487 PRODUCT_NAME = "$(TARGET_NAME)"; 496 PRODUCT_NAME = "$(TARGET_NAME)";
488 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 497 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
@@ -499,9 +508,13 @@ @@ -499,9 +508,13 @@
499 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 508 ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
500 CLANG_ENABLE_MODULES = YES; 509 CLANG_ENABLE_MODULES = YES;
501 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 510 CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
  511 + DEVELOPMENT_TEAM = EC2XFC58R3;
502 ENABLE_BITCODE = NO; 512 ENABLE_BITCODE = NO;
503 INFOPLIST_FILE = Runner/Info.plist; 513 INFOPLIST_FILE = Runner/Info.plist;
504 - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 514 + LD_RUNPATH_SEARCH_PATHS = (
  515 + "$(inherited)",
  516 + "@executable_path/Frameworks",
  517 + );
505 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo; 518 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo;
506 PRODUCT_NAME = "$(TARGET_NAME)"; 519 PRODUCT_NAME = "$(TARGET_NAME)";
507 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 520 SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
@@ -536,4 +549,4 @@ @@ -536,4 +549,4 @@
536 /* End XCConfigurationList section */ 549 /* End XCConfigurationList section */
537 }; 550 };
538 rootObject = 97C146E61CF9000F007C117D /* Project object */; 551 rootObject = 97C146E61CF9000F007C117D /* Project object */;
539 -} 552 +}
@@ -2,6 +2,6 @@ @@ -2,6 +2,6 @@
2 <Workspace 2 <Workspace
3 version = "1.0"> 3 version = "1.0">
4 <FileRef 4 <FileRef
5 - location = "group:Runner.xcodeproj"> 5 + location = "self:">
6 </FileRef> 6 </FileRef>
7 </Workspace> 7 </Workspace>
1 <?xml version="1.0" encoding="UTF-8"?> 1 <?xml version="1.0" encoding="UTF-8"?>
2 <Scheme 2 <Scheme
3 - LastUpgradeVersion = "1020" 3 + LastUpgradeVersion = "1300"
4 version = "1.3"> 4 version = "1.3">
5 <BuildAction 5 <BuildAction
6 parallelizeBuildables = "YES" 6 parallelizeBuildables = "YES"
@@ -27,8 +27,6 @@ @@ -27,8 +27,6 @@
27 selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" 27 selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
28 selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" 28 selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
29 shouldUseLaunchSchemeArgsEnv = "YES"> 29 shouldUseLaunchSchemeArgsEnv = "YES">
30 - <Testables>  
31 - </Testables>  
32 <MacroExpansion> 30 <MacroExpansion>
33 <BuildableReference 31 <BuildableReference
34 BuildableIdentifier = "primary" 32 BuildableIdentifier = "primary"
@@ -38,8 +36,8 @@ @@ -38,8 +36,8 @@
38 ReferencedContainer = "container:Runner.xcodeproj"> 36 ReferencedContainer = "container:Runner.xcodeproj">
39 </BuildableReference> 37 </BuildableReference>
40 </MacroExpansion> 38 </MacroExpansion>
41 - <AdditionalOptions>  
42 - </AdditionalOptions> 39 + <Testables>
  40 + </Testables>
43 </TestAction> 41 </TestAction>
44 <LaunchAction 42 <LaunchAction
45 buildConfiguration = "Debug" 43 buildConfiguration = "Debug"
@@ -61,8 +59,6 @@ @@ -61,8 +59,6 @@
61 ReferencedContainer = "container:Runner.xcodeproj"> 59 ReferencedContainer = "container:Runner.xcodeproj">
62 </BuildableReference> 60 </BuildableReference>
63 </BuildableProductRunnable> 61 </BuildableProductRunnable>
64 - <AdditionalOptions>  
65 - </AdditionalOptions>  
66 </LaunchAction> 62 </LaunchAction>
67 <ProfileAction 63 <ProfileAction
68 buildConfiguration = "Profile" 64 buildConfiguration = "Profile"
@@ -4,6 +4,8 @@ @@ -4,6 +4,8 @@
4 <dict> 4 <dict>
5 <key>CFBundleDevelopmentRegion</key> 5 <key>CFBundleDevelopmentRegion</key>
6 <string>$(DEVELOPMENT_LANGUAGE)</string> 6 <string>$(DEVELOPMENT_LANGUAGE)</string>
  7 + <key>CFBundleDisplayName</key>
  8 + <string>Flutter PDF Demo</string>
7 <key>CFBundleExecutable</key> 9 <key>CFBundleExecutable</key>
8 <string>$(EXECUTABLE_NAME)</string> 10 <string>$(EXECUTABLE_NAME)</string>
9 <key>CFBundleIdentifier</key> 11 <key>CFBundleIdentifier</key>
@@ -11,7 +13,7 @@ @@ -11,7 +13,7 @@
11 <key>CFBundleInfoDictionaryVersion</key> 13 <key>CFBundleInfoDictionaryVersion</key>
12 <string>6.0</string> 14 <string>6.0</string>
13 <key>CFBundleName</key> 15 <key>CFBundleName</key>
14 - <string>printing_demo</string> 16 + <string>Pdf Printing Demo</string>
15 <key>CFBundlePackageType</key> 17 <key>CFBundlePackageType</key>
16 <string>APPL</string> 18 <string>APPL</string>
17 <key>CFBundleShortVersionString</key> 19 <key>CFBundleShortVersionString</key>
@@ -45,5 +47,9 @@ @@ -45,5 +47,9 @@
45 </array> 47 </array>
46 <key>UIViewControllerBasedStatusBarAppearance</key> 48 <key>UIViewControllerBasedStatusBarAppearance</key>
47 <false/> 49 <false/>
  50 + <key>CADisableMinimumFrameDurationOnPhone</key>
  51 + <true/>
  52 + <key>UIApplicationSupportsIndirectInputEvents</key>
  53 + <true/>
48 </dict> 54 </dict>
49 </plist> 55 </plist>
  1 +flutter/ephemeral
  1 +# Project-level configuration.
  2 +cmake_minimum_required(VERSION 3.10)
  3 +project(runner LANGUAGES CXX)
  4 +
  5 +# The name of the executable created for the application. Change this to change
  6 +# the on-disk name of your application.
  7 +set(BINARY_NAME "printing_demo")
  8 +# The unique GTK application identifier for this application. See:
  9 +# https://wiki.gnome.org/HowDoI/ChooseApplicationID
  10 +set(APPLICATION_ID "net.nfet.printing_demo")
  11 +
  12 +# Explicitly opt in to modern CMake behaviors to avoid warnings with recent
  13 +# versions of CMake.
  14 +cmake_policy(SET CMP0063 NEW)
  15 +
  16 +# Load bundled libraries from the lib/ directory relative to the binary.
  17 +set(CMAKE_INSTALL_RPATH "$ORIGIN/lib")
  18 +
  19 +# Root filesystem for cross-building.
  20 +if(FLUTTER_TARGET_PLATFORM_SYSROOT)
  21 + set(CMAKE_SYSROOT ${FLUTTER_TARGET_PLATFORM_SYSROOT})
  22 + set(CMAKE_FIND_ROOT_PATH ${CMAKE_SYSROOT})
  23 + set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
  24 + set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
  25 + set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
  26 + set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
  27 +endif()
  28 +
  29 +# Define build configuration options.
  30 +if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
  31 + set(CMAKE_BUILD_TYPE "Debug" CACHE
  32 + STRING "Flutter build mode" FORCE)
  33 + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
  34 + "Debug" "Profile" "Release")
  35 +endif()
  36 +
  37 +# Compilation settings that should be applied to most targets.
  38 +#
  39 +# Be cautious about adding new options here, as plugins use this function by
  40 +# default. In most cases, you should add new options to specific targets instead
  41 +# of modifying this function.
  42 +function(APPLY_STANDARD_SETTINGS TARGET)
  43 + target_compile_features(${TARGET} PUBLIC cxx_std_14)
  44 + target_compile_options(${TARGET} PRIVATE -Wall -Werror)
  45 + target_compile_options(${TARGET} PRIVATE "$<$<NOT:$<CONFIG:Debug>>:-O3>")
  46 + target_compile_definitions(${TARGET} PRIVATE "$<$<NOT:$<CONFIG:Debug>>:NDEBUG>")
  47 +endfunction()
  48 +
  49 +# Flutter library and tool build rules.
  50 +set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter")
  51 +add_subdirectory(${FLUTTER_MANAGED_DIR})
  52 +
  53 +# System-level dependencies.
  54 +find_package(PkgConfig REQUIRED)
  55 +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0)
  56 +
  57 +add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}")
  58 +
  59 +# Define the application target. To change its name, change BINARY_NAME above,
  60 +# not the value here, or `flutter run` will no longer work.
  61 +#
  62 +# Any new source files that you add to the application should be added here.
  63 +add_executable(${BINARY_NAME}
  64 + "main.cc"
  65 + "my_application.cc"
  66 + "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
  67 +)
  68 +
  69 +# Apply the standard set of build settings. This can be removed for applications
  70 +# that need different build settings.
  71 +apply_standard_settings(${BINARY_NAME})
  72 +
  73 +# Add dependency libraries. Add any application-specific dependencies here.
  74 +target_link_libraries(${BINARY_NAME} PRIVATE flutter)
  75 +target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK)
  76 +
  77 +# Run the Flutter tool portions of the build. This must not be removed.
  78 +add_dependencies(${BINARY_NAME} flutter_assemble)
  79 +
  80 +# Only the install-generated bundle's copy of the executable will launch
  81 +# correctly, since the resources must in the right relative locations. To avoid
  82 +# people trying to run the unbundled copy, put it in a subdirectory instead of
  83 +# the default top-level location.
  84 +set_target_properties(${BINARY_NAME}
  85 + PROPERTIES
  86 + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/intermediates_do_not_run"
  87 +)
  88 +
  89 +# Generated plugin build rules, which manage building the plugins and adding
  90 +# them to the application.
  91 +include(flutter/generated_plugins.cmake)
  92 +
  93 +
  94 +# === Installation ===
  95 +# By default, "installing" just makes a relocatable bundle in the build
  96 +# directory.
  97 +set(BUILD_BUNDLE_DIR "${PROJECT_BINARY_DIR}/bundle")
  98 +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
  99 + set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE)
  100 +endif()
  101 +
  102 +# Start with a clean build bundle directory every time.
  103 +install(CODE "
  104 + file(REMOVE_RECURSE \"${BUILD_BUNDLE_DIR}/\")
  105 + " COMPONENT Runtime)
  106 +
  107 +set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data")
  108 +set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib")
  109 +
  110 +install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}"
  111 + COMPONENT Runtime)
  112 +
  113 +install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
  114 + COMPONENT Runtime)
  115 +
  116 +install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
  117 + COMPONENT Runtime)
  118 +
  119 +foreach(bundled_library ${PLUGIN_BUNDLED_LIBRARIES})
  120 + install(FILES "${bundled_library}"
  121 + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
  122 + COMPONENT Runtime)
  123 +endforeach(bundled_library)
  124 +
  125 +# Fully re-copy the assets directory on each build to avoid having stale files
  126 +# from a previous install.
  127 +set(FLUTTER_ASSET_DIR_NAME "flutter_assets")
  128 +install(CODE "
  129 + file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\")
  130 + " COMPONENT Runtime)
  131 +install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}"
  132 + DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime)
  133 +
  134 +# Install the AOT library on non-Debug builds only.
  135 +if(NOT CMAKE_BUILD_TYPE MATCHES "Debug")
  136 + install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
  137 + COMPONENT Runtime)
  138 +endif()
  1 +# This file controls Flutter-level build steps. It should not be edited.
  2 +cmake_minimum_required(VERSION 3.10)
  3 +
  4 +set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral")
  5 +
  6 +# Configuration provided via flutter tool.
  7 +include(${EPHEMERAL_DIR}/generated_config.cmake)
  8 +
  9 +# TODO: Move the rest of this into files in ephemeral. See
  10 +# https://github.com/flutter/flutter/issues/57146.
  11 +
  12 +# Serves the same purpose as list(TRANSFORM ... PREPEND ...),
  13 +# which isn't available in 3.10.
  14 +function(list_prepend LIST_NAME PREFIX)
  15 + set(NEW_LIST "")
  16 + foreach(element ${${LIST_NAME}})
  17 + list(APPEND NEW_LIST "${PREFIX}${element}")
  18 + endforeach(element)
  19 + set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE)
  20 +endfunction()
  21 +
  22 +# === Flutter Library ===
  23 +# System-level dependencies.
  24 +find_package(PkgConfig REQUIRED)
  25 +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0)
  26 +pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0)
  27 +pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0)
  28 +
  29 +set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so")
  30 +
  31 +# Published to parent scope for install step.
  32 +set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE)
  33 +set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE)
  34 +set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE)
  35 +set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE)
  36 +
  37 +list(APPEND FLUTTER_LIBRARY_HEADERS
  38 + "fl_basic_message_channel.h"
  39 + "fl_binary_codec.h"
  40 + "fl_binary_messenger.h"
  41 + "fl_dart_project.h"
  42 + "fl_engine.h"
  43 + "fl_json_message_codec.h"
  44 + "fl_json_method_codec.h"
  45 + "fl_message_codec.h"
  46 + "fl_method_call.h"
  47 + "fl_method_channel.h"
  48 + "fl_method_codec.h"
  49 + "fl_method_response.h"
  50 + "fl_plugin_registrar.h"
  51 + "fl_plugin_registry.h"
  52 + "fl_standard_message_codec.h"
  53 + "fl_standard_method_codec.h"
  54 + "fl_string_codec.h"
  55 + "fl_value.h"
  56 + "fl_view.h"
  57 + "flutter_linux.h"
  58 +)
  59 +list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/")
  60 +add_library(flutter INTERFACE)
  61 +target_include_directories(flutter INTERFACE
  62 + "${EPHEMERAL_DIR}"
  63 +)
  64 +target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}")
  65 +target_link_libraries(flutter INTERFACE
  66 + PkgConfig::GTK
  67 + PkgConfig::GLIB
  68 + PkgConfig::GIO
  69 +)
  70 +add_dependencies(flutter flutter_assemble)
  71 +
  72 +# === Flutter tool backend ===
  73 +# _phony_ is a non-existent file to force this command to run every time,
  74 +# since currently there's no way to get a full input/output list from the
  75 +# flutter tool.
  76 +add_custom_command(
  77 + OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS}
  78 + ${CMAKE_CURRENT_BINARY_DIR}/_phony_
  79 + COMMAND ${CMAKE_COMMAND} -E env
  80 + ${FLUTTER_TOOL_ENVIRONMENT}
  81 + "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh"
  82 + ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE}
  83 + VERBATIM
  84 +)
  85 +add_custom_target(flutter_assemble DEPENDS
  86 + "${FLUTTER_LIBRARY}"
  87 + ${FLUTTER_LIBRARY_HEADERS}
  88 +)
  1 +//
  2 +// Generated file. Do not edit.
  3 +//
  4 +
  5 +// clang-format off
  6 +
  7 +#include "generated_plugin_registrant.h"
  8 +
  9 +#include <printing/printing_plugin.h>
  10 +#include <url_launcher_linux/url_launcher_plugin.h>
  11 +
  12 +void fl_register_plugins(FlPluginRegistry* registry) {
  13 + g_autoptr(FlPluginRegistrar) printing_registrar =
  14 + fl_plugin_registry_get_registrar_for_plugin(registry, "PrintingPlugin");
  15 + printing_plugin_register_with_registrar(printing_registrar);
  16 + g_autoptr(FlPluginRegistrar) url_launcher_linux_registrar =
  17 + fl_plugin_registry_get_registrar_for_plugin(registry, "UrlLauncherPlugin");
  18 + url_launcher_plugin_register_with_registrar(url_launcher_linux_registrar);
  19 +}
  1 +//
  2 +// Generated file. Do not edit.
  3 +//
  4 +
  5 +// clang-format off
  6 +
  7 +#ifndef GENERATED_PLUGIN_REGISTRANT_
  8 +#define GENERATED_PLUGIN_REGISTRANT_
  9 +
  10 +#include <flutter_linux/flutter_linux.h>
  11 +
  12 +// Registers Flutter plugins.
  13 +void fl_register_plugins(FlPluginRegistry* registry);
  14 +
  15 +#endif // GENERATED_PLUGIN_REGISTRANT_
  1 +#
  2 +# Generated file, do not edit.
  3 +#
  4 +
  5 +list(APPEND FLUTTER_PLUGIN_LIST
  6 + printing
  7 + url_launcher_linux
  8 +)
  9 +
  10 +list(APPEND FLUTTER_FFI_PLUGIN_LIST
  11 +)
  12 +
  13 +set(PLUGIN_BUNDLED_LIBRARIES)
  14 +
  15 +foreach(plugin ${FLUTTER_PLUGIN_LIST})
  16 + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin})
  17 + target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin)
  18 + list(APPEND PLUGIN_BUNDLED_LIBRARIES $<TARGET_FILE:${plugin}_plugin>)
  19 + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries})
  20 +endforeach(plugin)
  21 +
  22 +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST})
  23 + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin})
  24 + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries})
  25 +endforeach(ffi_plugin)
  1 +#include "my_application.h"
  2 +
  3 +int main(int argc, char** argv) {
  4 + g_autoptr(MyApplication) app = my_application_new();
  5 + return g_application_run(G_APPLICATION(app), argc, argv);
  6 +}
  1 +#include "my_application.h"
  2 +
  3 +#include <flutter_linux/flutter_linux.h>
  4 +#ifdef GDK_WINDOWING_X11
  5 +#include <gdk/gdkx.h>
  6 +#endif
  7 +
  8 +#include "flutter/generated_plugin_registrant.h"
  9 +
  10 +struct _MyApplication {
  11 + GtkApplication parent_instance;
  12 + char** dart_entrypoint_arguments;
  13 +};
  14 +
  15 +G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION)
  16 +
  17 +// Implements GApplication::activate.
  18 +static void my_application_activate(GApplication* application) {
  19 + MyApplication* self = MY_APPLICATION(application);
  20 + GtkWindow* window =
  21 + GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application)));
  22 +
  23 + // Use a header bar when running in GNOME as this is the common style used
  24 + // by applications and is the setup most users will be using (e.g. Ubuntu
  25 + // desktop).
  26 + // If running on X and not using GNOME then just use a traditional title bar
  27 + // in case the window manager does more exotic layout, e.g. tiling.
  28 + // If running on Wayland assume the header bar will work (may need changing
  29 + // if future cases occur).
  30 + gboolean use_header_bar = TRUE;
  31 +#ifdef GDK_WINDOWING_X11
  32 + GdkScreen* screen = gtk_window_get_screen(window);
  33 + if (GDK_IS_X11_SCREEN(screen)) {
  34 + const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen);
  35 + if (g_strcmp0(wm_name, "GNOME Shell") != 0) {
  36 + use_header_bar = FALSE;
  37 + }
  38 + }
  39 +#endif
  40 + if (use_header_bar) {
  41 + GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new());
  42 + gtk_widget_show(GTK_WIDGET(header_bar));
  43 + gtk_header_bar_set_title(header_bar, "Flutter PDF Demo");
  44 + gtk_header_bar_set_show_close_button(header_bar, TRUE);
  45 + gtk_window_set_titlebar(window, GTK_WIDGET(header_bar));
  46 + } else {
  47 + gtk_window_set_title(window, "Flutter PDF Demo");
  48 + }
  49 +
  50 + gtk_window_set_default_size(window, 1280, 720);
  51 + gtk_widget_show(GTK_WIDGET(window));
  52 +
  53 + g_autoptr(FlDartProject) project = fl_dart_project_new();
  54 + fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments);
  55 +
  56 + FlView* view = fl_view_new(project);
  57 + gtk_widget_show(GTK_WIDGET(view));
  58 + gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view));
  59 +
  60 + fl_register_plugins(FL_PLUGIN_REGISTRY(view));
  61 +
  62 + gtk_widget_grab_focus(GTK_WIDGET(view));
  63 +}
  64 +
  65 +// Implements GApplication::local_command_line.
  66 +static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) {
  67 + MyApplication* self = MY_APPLICATION(application);
  68 + // Strip out the first argument as it is the binary name.
  69 + self->dart_entrypoint_arguments = g_strdupv(*arguments + 1);
  70 +
  71 + g_autoptr(GError) error = nullptr;
  72 + if (!g_application_register(application, nullptr, &error)) {
  73 + g_warning("Failed to register: %s", error->message);
  74 + *exit_status = 1;
  75 + return TRUE;
  76 + }
  77 +
  78 + g_application_activate(application);
  79 + *exit_status = 0;
  80 +
  81 + return TRUE;
  82 +}
  83 +
  84 +// Implements GObject::dispose.
  85 +static void my_application_dispose(GObject* object) {
  86 + MyApplication* self = MY_APPLICATION(object);
  87 + g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev);
  88 + G_OBJECT_CLASS(my_application_parent_class)->dispose(object);
  89 +}
  90 +
  91 +static void my_application_class_init(MyApplicationClass* klass) {
  92 + G_APPLICATION_CLASS(klass)->activate = my_application_activate;
  93 + G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line;
  94 + G_OBJECT_CLASS(klass)->dispose = my_application_dispose;
  95 +}
  96 +
  97 +static void my_application_init(MyApplication* self) {}
  98 +
  99 +MyApplication* my_application_new() {
  100 + return MY_APPLICATION(g_object_new(my_application_get_type(),
  101 + "application-id", APPLICATION_ID,
  102 + "flags", G_APPLICATION_NON_UNIQUE,
  103 + nullptr));
  104 +}
  1 +#ifndef FLUTTER_MY_APPLICATION_H_
  2 +#define FLUTTER_MY_APPLICATION_H_
  3 +
  4 +#include <gtk/gtk.h>
  5 +
  6 +G_DECLARE_FINAL_TYPE(MyApplication, my_application, MY, APPLICATION,
  7 + GtkApplication)
  8 +
  9 +/**
  10 + * my_application_new:
  11 + *
  12 + * Creates a new Flutter-based application.
  13 + *
  14 + * Returns: a new #MyApplication.
  15 + */
  16 +MyApplication* my_application_new();
  17 +
  18 +#endif // FLUTTER_MY_APPLICATION_H_
@@ -3,6 +3,9 @@ @@ -3,6 +3,9 @@
3 **/Pods/ 3 **/Pods/
4 4
5 # Xcode-related 5 # Xcode-related
  6 +**/dgph
6 **/xcuserdata/ 7 **/xcuserdata/
7 8
8 Flutter/GeneratedPluginRegistrant.swift 9 Flutter/GeneratedPluginRegistrant.swift
  10 +
  11 +Podfile.lock
1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"  
3 #include "ephemeral/Flutter-Generated.xcconfig" 2 #include "ephemeral/Flutter-Generated.xcconfig"
1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 1 #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"  
3 #include "ephemeral/Flutter-Generated.xcconfig" 2 #include "ephemeral/Flutter-Generated.xcconfig"
@@ -26,7 +26,7 @@ @@ -26,7 +26,7 @@
26 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; }; 26 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; };
27 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; }; 27 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; };
28 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; }; 28 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; };
29 - 431DC00351DB0DC4ABC58D3B /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 965F29CC9777229324768DEB /* Pods_Runner.framework */; }; 29 + A8917C5EF549C02AEB9FA407 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A809316FF0F162F408487748 /* Pods_Runner.framework */; };
30 /* End PBXBuildFile section */ 30 /* End PBXBuildFile section */
31 31
32 /* Begin PBXContainerItemProxy section */ 32 /* Begin PBXContainerItemProxy section */
@@ -53,9 +53,10 @@ @@ -53,9 +53,10 @@
53 /* End PBXCopyFilesBuildPhase section */ 53 /* End PBXCopyFilesBuildPhase section */
54 54
55 /* Begin PBXFileReference section */ 55 /* Begin PBXFileReference section */
  56 + 0A0CD5D923B8D69FE391414F /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
56 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = "<group>"; }; 57 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = "<group>"; };
57 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = "<group>"; }; 58 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = "<group>"; };
58 - 33CC10ED2044A3C60003C045 /* printing_demo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = printing_demo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 59 + 33CC10ED2044A3C60003C045 /* Pdf Printing Demo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Pdf Printing Demo.app"; sourceTree = BUILT_PRODUCTS_DIR; };
59 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; }; 60 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
60 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = "<group>"; }; 61 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = "<group>"; };
61 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = "<group>"; }; 62 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = "<group>"; };
@@ -67,12 +68,11 @@ @@ -67,12 +68,11 @@
67 33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = "<group>"; }; 68 33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = "<group>"; };
68 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = "<group>"; }; 69 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = "<group>"; };
69 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = "<group>"; }; 70 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = "<group>"; };
70 - 367A2D34FF5ABCEBA50C2D9F /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };  
71 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = "<group>"; }; 71 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = "<group>"; };
72 - 965F29CC9777229324768DEB /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };  
73 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = "<group>"; }; 72 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = "<group>"; };
74 - AD2199B14072A81AC81343D7 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };  
75 - C23983A634DCC94446D395FD /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; }; 73 + A5FF8547FE6A223BFC39C84D /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
  74 + A809316FF0F162F408487748 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
  75 + BA93256B686336B78D9D78E5 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
76 /* End PBXFileReference section */ 76 /* End PBXFileReference section */
77 77
78 /* Begin PBXFrameworksBuildPhase section */ 78 /* Begin PBXFrameworksBuildPhase section */
@@ -80,7 +80,7 @@ @@ -80,7 +80,7 @@
80 isa = PBXFrameworksBuildPhase; 80 isa = PBXFrameworksBuildPhase;
81 buildActionMask = 2147483647; 81 buildActionMask = 2147483647;
82 files = ( 82 files = (
83 - 431DC00351DB0DC4ABC58D3B /* Pods_Runner.framework in Frameworks */, 83 + A8917C5EF549C02AEB9FA407 /* Pods_Runner.framework in Frameworks */,
84 ); 84 );
85 runOnlyForDeploymentPostprocessing = 0; 85 runOnlyForDeploymentPostprocessing = 0;
86 }; 86 };
@@ -105,14 +105,14 @@ @@ -105,14 +105,14 @@
105 33CEB47122A05771004F2AC0 /* Flutter */, 105 33CEB47122A05771004F2AC0 /* Flutter */,
106 33CC10EE2044A3C60003C045 /* Products */, 106 33CC10EE2044A3C60003C045 /* Products */,
107 D73912EC22F37F3D000D13A0 /* Frameworks */, 107 D73912EC22F37F3D000D13A0 /* Frameworks */,
108 - EDECF6CA21D3808849201DCA /* Pods */, 108 + 9FC37C35BCBE344D145D7AA6 /* Pods */,
109 ); 109 );
110 sourceTree = "<group>"; 110 sourceTree = "<group>";
111 }; 111 };
112 33CC10EE2044A3C60003C045 /* Products */ = { 112 33CC10EE2044A3C60003C045 /* Products */ = {
113 isa = PBXGroup; 113 isa = PBXGroup;
114 children = ( 114 children = (
115 - 33CC10ED2044A3C60003C045 /* printing_demo.app */, 115 + 33CC10ED2044A3C60003C045 /* Pdf Printing Demo.app */,
116 ); 116 );
117 name = Products; 117 name = Products;
118 sourceTree = "<group>"; 118 sourceTree = "<group>";
@@ -152,23 +152,22 @@ @@ -152,23 +152,22 @@
152 path = Runner; 152 path = Runner;
153 sourceTree = "<group>"; 153 sourceTree = "<group>";
154 }; 154 };
155 - D73912EC22F37F3D000D13A0 /* Frameworks */ = { 155 + 9FC37C35BCBE344D145D7AA6 /* Pods */ = {
156 isa = PBXGroup; 156 isa = PBXGroup;
157 children = ( 157 children = (
158 - 965F29CC9777229324768DEB /* Pods_Runner.framework */, 158 + 0A0CD5D923B8D69FE391414F /* Pods-Runner.debug.xcconfig */,
  159 + BA93256B686336B78D9D78E5 /* Pods-Runner.release.xcconfig */,
  160 + A5FF8547FE6A223BFC39C84D /* Pods-Runner.profile.xcconfig */,
159 ); 161 );
160 - name = Frameworks; 162 + path = Pods;
161 sourceTree = "<group>"; 163 sourceTree = "<group>";
162 }; 164 };
163 - EDECF6CA21D3808849201DCA /* Pods */ = { 165 + D73912EC22F37F3D000D13A0 /* Frameworks */ = {
164 isa = PBXGroup; 166 isa = PBXGroup;
165 children = ( 167 children = (
166 - AD2199B14072A81AC81343D7 /* Pods-Runner.debug.xcconfig */,  
167 - 367A2D34FF5ABCEBA50C2D9F /* Pods-Runner.release.xcconfig */,  
168 - C23983A634DCC94446D395FD /* Pods-Runner.profile.xcconfig */, 168 + A809316FF0F162F408487748 /* Pods_Runner.framework */,
169 ); 169 );
170 - name = Pods;  
171 - path = Pods; 170 + name = Frameworks;
172 sourceTree = "<group>"; 171 sourceTree = "<group>";
173 }; 172 };
174 /* End PBXGroup section */ 173 /* End PBXGroup section */
@@ -178,13 +177,13 @@ @@ -178,13 +177,13 @@
178 isa = PBXNativeTarget; 177 isa = PBXNativeTarget;
179 buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */; 178 buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */;
180 buildPhases = ( 179 buildPhases = (
181 - 89CE2260822865068C68F8D9 /* [CP] Check Pods Manifest.lock */, 180 + 99C78CA3A3D0A6136750E248 /* [CP] Check Pods Manifest.lock */,
182 33CC10E92044A3C60003C045 /* Sources */, 181 33CC10E92044A3C60003C045 /* Sources */,
183 33CC10EA2044A3C60003C045 /* Frameworks */, 182 33CC10EA2044A3C60003C045 /* Frameworks */,
184 33CC10EB2044A3C60003C045 /* Resources */, 183 33CC10EB2044A3C60003C045 /* Resources */,
185 33CC110E2044A8840003C045 /* Bundle Framework */, 184 33CC110E2044A8840003C045 /* Bundle Framework */,
186 3399D490228B24CF009A79C7 /* ShellScript */, 185 3399D490228B24CF009A79C7 /* ShellScript */,
187 - C0E12BE65A32419A3B2F1F21 /* [CP] Embed Pods Frameworks */, 186 + 4F68BD8A09615A8F1FB7FBA0 /* [CP] Embed Pods Frameworks */,
188 ); 187 );
189 buildRules = ( 188 buildRules = (
190 ); 189 );
@@ -193,7 +192,7 @@ @@ -193,7 +192,7 @@
193 ); 192 );
194 name = Runner; 193 name = Runner;
195 productName = Runner; 194 productName = Runner;
196 - productReference = 33CC10ED2044A3C60003C045 /* printing_demo.app */; 195 + productReference = 33CC10ED2044A3C60003C045 /* Pdf Printing Demo.app */;
197 productType = "com.apple.product-type.application"; 196 productType = "com.apple.product-type.application";
198 }; 197 };
199 /* End PBXNativeTarget section */ 198 /* End PBXNativeTarget section */
@@ -203,7 +202,7 @@ @@ -203,7 +202,7 @@
203 isa = PBXProject; 202 isa = PBXProject;
204 attributes = { 203 attributes = {
205 LastSwiftUpdateCheck = 0920; 204 LastSwiftUpdateCheck = 0920;
206 - LastUpgradeCheck = 0930; 205 + LastUpgradeCheck = 1300;
207 ORGANIZATIONNAME = ""; 206 ORGANIZATIONNAME = "";
208 TargetAttributes = { 207 TargetAttributes = {
209 33CC10EC2044A3C60003C045 = { 208 33CC10EC2044A3C60003C045 = {
@@ -291,43 +290,43 @@ @@ -291,43 +290,43 @@
291 shellPath = /bin/sh; 290 shellPath = /bin/sh;
292 shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire"; 291 shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire";
293 }; 292 };
294 - 89CE2260822865068C68F8D9 /* [CP] Check Pods Manifest.lock */ = { 293 + 4F68BD8A09615A8F1FB7FBA0 /* [CP] Embed Pods Frameworks */ = {
295 isa = PBXShellScriptBuildPhase; 294 isa = PBXShellScriptBuildPhase;
296 buildActionMask = 2147483647; 295 buildActionMask = 2147483647;
297 files = ( 296 files = (
298 ); 297 );
299 inputFileListPaths = ( 298 inputFileListPaths = (
  299 + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
300 ); 300 );
301 - inputPaths = (  
302 - "${PODS_PODFILE_DIR_PATH}/Podfile.lock",  
303 - "${PODS_ROOT}/Manifest.lock",  
304 - );  
305 - name = "[CP] Check Pods Manifest.lock"; 301 + name = "[CP] Embed Pods Frameworks";
306 outputFileListPaths = ( 302 outputFileListPaths = (
307 - );  
308 - outputPaths = (  
309 - "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", 303 + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
310 ); 304 );
311 runOnlyForDeploymentPostprocessing = 0; 305 runOnlyForDeploymentPostprocessing = 0;
312 shellPath = /bin/sh; 306 shellPath = /bin/sh;
313 - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 307 + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
314 showEnvVarsInLog = 0; 308 showEnvVarsInLog = 0;
315 }; 309 };
316 - C0E12BE65A32419A3B2F1F21 /* [CP] Embed Pods Frameworks */ = { 310 + 99C78CA3A3D0A6136750E248 /* [CP] Check Pods Manifest.lock */ = {
317 isa = PBXShellScriptBuildPhase; 311 isa = PBXShellScriptBuildPhase;
318 buildActionMask = 2147483647; 312 buildActionMask = 2147483647;
319 files = ( 313 files = (
320 ); 314 );
321 inputFileListPaths = ( 315 inputFileListPaths = (
322 - "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",  
323 ); 316 );
324 - name = "[CP] Embed Pods Frameworks"; 317 + inputPaths = (
  318 + "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
  319 + "${PODS_ROOT}/Manifest.lock",
  320 + );
  321 + name = "[CP] Check Pods Manifest.lock";
325 outputFileListPaths = ( 322 outputFileListPaths = (
326 - "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist", 323 + );
  324 + outputPaths = (
  325 + "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
327 ); 326 );
328 runOnlyForDeploymentPostprocessing = 0; 327 runOnlyForDeploymentPostprocessing = 0;
329 shellPath = /bin/sh; 328 shellPath = /bin/sh;
330 - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; 329 + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
331 showEnvVarsInLog = 0; 330 showEnvVarsInLog = 0;
332 }; 331 };
333 /* End PBXShellScriptBuildPhase section */ 332 /* End PBXShellScriptBuildPhase section */
@@ -421,10 +420,6 @@ @@ -421,10 +420,6 @@
421 CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; 420 CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
422 CODE_SIGN_STYLE = Automatic; 421 CODE_SIGN_STYLE = Automatic;
423 COMBINE_HIDPI_IMAGES = YES; 422 COMBINE_HIDPI_IMAGES = YES;
424 - FRAMEWORK_SEARCH_PATHS = (  
425 - "$(inherited)",  
426 - "$(PROJECT_DIR)/Flutter/ephemeral",  
427 - );  
428 INFOPLIST_FILE = Runner/Info.plist; 423 INFOPLIST_FILE = Runner/Info.plist;
429 LD_RUNPATH_SEARCH_PATHS = ( 424 LD_RUNPATH_SEARCH_PATHS = (
430 "$(inherited)", 425 "$(inherited)",
@@ -551,10 +546,6 @@ @@ -551,10 +546,6 @@
551 CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; 546 CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
552 CODE_SIGN_STYLE = Automatic; 547 CODE_SIGN_STYLE = Automatic;
553 COMBINE_HIDPI_IMAGES = YES; 548 COMBINE_HIDPI_IMAGES = YES;
554 - FRAMEWORK_SEARCH_PATHS = (  
555 - "$(inherited)",  
556 - "$(PROJECT_DIR)/Flutter/ephemeral",  
557 - );  
558 INFOPLIST_FILE = Runner/Info.plist; 549 INFOPLIST_FILE = Runner/Info.plist;
559 LD_RUNPATH_SEARCH_PATHS = ( 550 LD_RUNPATH_SEARCH_PATHS = (
560 "$(inherited)", 551 "$(inherited)",
@@ -575,10 +566,6 @@ @@ -575,10 +566,6 @@
575 CODE_SIGN_ENTITLEMENTS = Runner/Release.entitlements; 566 CODE_SIGN_ENTITLEMENTS = Runner/Release.entitlements;
576 CODE_SIGN_STYLE = Automatic; 567 CODE_SIGN_STYLE = Automatic;
577 COMBINE_HIDPI_IMAGES = YES; 568 COMBINE_HIDPI_IMAGES = YES;
578 - FRAMEWORK_SEARCH_PATHS = (  
579 - "$(inherited)",  
580 - "$(PROJECT_DIR)/Flutter/ephemeral",  
581 - );  
582 INFOPLIST_FILE = Runner/Info.plist; 569 INFOPLIST_FILE = Runner/Info.plist;
583 LD_RUNPATH_SEARCH_PATHS = ( 570 LD_RUNPATH_SEARCH_PATHS = (
584 "$(inherited)", 571 "$(inherited)",
1 <?xml version="1.0" encoding="UTF-8"?> 1 <?xml version="1.0" encoding="UTF-8"?>
2 <Scheme 2 <Scheme
3 - LastUpgradeVersion = "1000" 3 + LastUpgradeVersion = "1300"
4 version = "1.3"> 4 version = "1.3">
5 <BuildAction 5 <BuildAction
6 parallelizeBuildables = "YES" 6 parallelizeBuildables = "YES"
@@ -36,8 +36,8 @@ @@ -36,8 +36,8 @@
36 ReferencedContainer = "container:Runner.xcodeproj"> 36 ReferencedContainer = "container:Runner.xcodeproj">
37 </BuildableReference> 37 </BuildableReference>
38 </MacroExpansion> 38 </MacroExpansion>
39 - <AdditionalOptions>  
40 - </AdditionalOptions> 39 + <Testables>
  40 + </Testables>
41 </TestAction> 41 </TestAction>
42 <LaunchAction 42 <LaunchAction
43 buildConfiguration = "Debug" 43 buildConfiguration = "Debug"
@@ -59,8 +59,6 @@ @@ -59,8 +59,6 @@
59 ReferencedContainer = "container:Runner.xcodeproj"> 59 ReferencedContainer = "container:Runner.xcodeproj">
60 </BuildableReference> 60 </BuildableReference>
61 </BuildableProductRunnable> 61 </BuildableProductRunnable>
62 - <AdditionalOptions>  
63 - </AdditionalOptions>  
64 </LaunchAction> 62 </LaunchAction>
65 <ProfileAction 63 <ProfileAction
66 buildConfiguration = "Profile" 64 buildConfiguration = "Profile"
@@ -323,6 +323,10 @@ @@ -323,6 +323,10 @@
323 </items> 323 </items>
324 </menu> 324 </menu>
325 </menuItem> 325 </menuItem>
  326 + <menuItem title="Help" id="EPT-qC-fAb">
  327 + <modifierMask key="keyEquivalentModifierMask"/>
  328 + <menu key="submenu" title="Help" systemMenu="help" id="rJ0-wn-3NY"/>
  329 + </menuItem>
326 </items> 330 </items>
327 <point key="canvasLocation" x="142" y="-258"/> 331 <point key="canvasLocation" x="142" y="-258"/>
328 </menu> 332 </menu>
@@ -5,10 +5,10 @@ @@ -5,10 +5,10 @@
5 // 'flutter create' template. 5 // 'flutter create' template.
6 6
7 // The application's name. By default this is also the title of the Flutter window. 7 // The application's name. By default this is also the title of the Flutter window.
8 -PRODUCT_NAME = printing_demo 8 +PRODUCT_NAME = Pdf Printing Demo
9 9
10 // The application's bundle identifier 10 // The application's bundle identifier
11 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo 11 PRODUCT_BUNDLE_IDENTIFIER = net.nfet.printingDemo
12 12
13 // The copyright displayed in application information 13 // The copyright displayed in application information
14 -PRODUCT_COPYRIGHT = Copyright © 2020 net.nfet. All rights reserved. 14 +PRODUCT_COPYRIGHT = Copyright © 2022 net.nfet. All rights reserved.
@@ -2,6 +2,8 @@ @@ -2,6 +2,8 @@
2 <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> 2 <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3 <plist version="1.0"> 3 <plist version="1.0">
4 <dict> 4 <dict>
  5 + <key>LSApplicationCategoryType</key>
  6 + <string>public.app-category.utilities</string>
5 <key>CFBundleDevelopmentRegion</key> 7 <key>CFBundleDevelopmentRegion</key>
6 <string>$(DEVELOPMENT_LANGUAGE)</string> 8 <string>$(DEVELOPMENT_LANGUAGE)</string>
7 <key>CFBundleExecutable</key> 9 <key>CFBundleExecutable</key>
@@ -4,5 +4,9 @@ @@ -4,5 +4,9 @@
4 <dict> 4 <dict>
5 <key>com.apple.security.app-sandbox</key> 5 <key>com.apple.security.app-sandbox</key>
6 <true/> 6 <true/>
  7 + <key>com.apple.security.network.client</key>
  8 + <true/>
  9 + <key>com.apple.security.print</key>
  10 + <true/>
7 </dict> 11 </dict>
8 </plist> 12 </plist>
@@ -17,6 +17,7 @@ dependencies: @@ -17,6 +17,7 @@ dependencies:
17 url_launcher: ^6.0.6 17 url_launcher: ^6.0.6
18 18
19 dev_dependencies: 19 dev_dependencies:
  20 + flutter_launcher_icons: ^0.10.0
20 flutter_lints: ^1.0.4 21 flutter_lints: ^1.0.4
21 flutter_test: 22 flutter_test:
22 sdk: flutter 23 sdk: flutter
@@ -32,3 +33,15 @@ flutter: @@ -32,3 +33,15 @@ flutter:
32 uses-material-design: true 33 uses-material-design: true
33 assets: 34 assets:
34 - assets/ 35 - assets/
  36 +
  37 +flutter_icons:
  38 + image_path: "app-logo.png"
  39 + remove_alpha_ios: true
  40 + android:
  41 + generate: true
  42 + ios:
  43 + generate: true
  44 + web:
  45 + generate: true
  46 + windows:
  47 + generate: true
@@ -24,81 +24,35 @@ @@ -24,81 +24,35 @@
24 <meta name="apple-mobile-web-app-capable" content="yes"> 24 <meta name="apple-mobile-web-app-capable" content="yes">
25 <meta name="apple-mobile-web-app-status-bar-style" content="black"> 25 <meta name="apple-mobile-web-app-status-bar-style" content="black">
26 <meta name="apple-mobile-web-app-title" content="Flutter PDF Demo"> 26 <meta name="apple-mobile-web-app-title" content="Flutter PDF Demo">
27 - <link rel="apple-touch-icon" href="icon-192.png"> 27 + <link rel="apple-touch-icon" href="icons/Icon-192.png">
28 28
29 <!-- Favicon --> 29 <!-- Favicon -->
30 <link rel="icon" type="image/png" href="favicon.png"/> 30 <link rel="icon" type="image/png" href="favicon.png"/>
31 31
32 <title>Flutter PDF Demo</title> 32 <title>Flutter PDF Demo</title>
33 <link rel="manifest" href="manifest.json"> 33 <link rel="manifest" href="manifest.json">
  34 +
  35 + <script>
  36 + // The value below is injected by flutter build, do not touch.
  37 + var serviceWorkerVersion = null;
  38 + </script>
  39 + <!-- This script adds the flutter initialization JS code -->
  40 + <script src="flutter.js" defer></script>
34 </head> 41 </head>
35 <body> 42 <body>
36 - <!-- This script installs service_worker.js to provide PWA functionality to  
37 - application. For more information, see:  
38 - https://developers.google.com/web/fundamentals/primers/service-workers -->  
39 <script> 43 <script>
40 - var serviceWorkerVersion = null;  
41 - var scriptLoaded = false;  
42 - function loadMainDartJs() {  
43 - if (scriptLoaded) {  
44 - return;  
45 - }  
46 - scriptLoaded = true;  
47 - var scriptTag = document.createElement('script');  
48 - scriptTag.src = 'main.dart.js';  
49 - scriptTag.type = 'application/javascript';  
50 - document.body.append(scriptTag);  
51 - }  
52 -  
53 - if ('serviceWorker' in navigator) {  
54 - // Service workers are supported. Use them.  
55 - window.addEventListener('load', function () {  
56 - // Wait for registration to finish before dropping the <script> tag.  
57 - // Otherwise, the browser will load the script multiple times,  
58 - // potentially different versions.  
59 - var serviceWorkerUrl = 'flutter_service_worker.js?v=' + serviceWorkerVersion;  
60 - navigator.serviceWorker.register(serviceWorkerUrl)  
61 - .then((reg) => {  
62 - function waitForActivation(serviceWorker) {  
63 - serviceWorker.addEventListener('statechange', () => {  
64 - if (serviceWorker.state == 'activated') {  
65 - console.log('Installed new service worker.');  
66 - loadMainDartJs();  
67 - }  
68 - });  
69 - }  
70 - if (!reg.active && (reg.installing || reg.waiting)) {  
71 - // No active web worker and we have installed or are installing  
72 - // one for the first time. Simply wait for it to activate.  
73 - waitForActivation(reg.installing || reg.waiting);  
74 - } else if (!reg.active.scriptURL.endsWith(serviceWorkerVersion)) {  
75 - // When the app updates the serviceWorkerVersion changes, so we  
76 - // need to ask the service worker to update.  
77 - console.log('New service worker available.');  
78 - reg.update();  
79 - waitForActivation(reg.installing);  
80 - } else {  
81 - // Existing service worker is still good.  
82 - console.log('Loading app from service worker.');  
83 - loadMainDartJs();  
84 - }  
85 - });  
86 -  
87 - // If service worker doesn't succeed in a reasonable amount of time,  
88 - // fallback to plaint <script> tag.  
89 - setTimeout(() => {  
90 - if (!scriptLoaded) {  
91 - console.warn(  
92 - 'Failed to load app from service worker. Falling back to plain <script> tag.',  
93 - );  
94 - loadMainDartJs();  
95 - }  
96 - }, 4000); 44 + window.addEventListener('load', function(ev) {
  45 + // Download main.dart.js
  46 + _flutter.loader.loadEntrypoint({
  47 + serviceWorker: {
  48 + serviceWorkerVersion: serviceWorkerVersion,
  49 + }
  50 + }).then(function(engineInitializer) {
  51 + return engineInitializer.initializeEngine();
  52 + }).then(function(appRunner) {
  53 + return appRunner.runApp();
97 }); 54 });
98 - } else {  
99 - // Service workers not supported. Just drop the <script> tag.  
100 - loadMainDartJs();  
101 - } 55 + });
102 </script> 56 </script>
103 </body> 57 </body>
104 </html> 58 </html>
1 { 1 {
2 - "name": "Flutter PDF Demo",  
3 - "short_name": "Flutter PDF Demo",  
4 - "start_url": ".",  
5 - "display": "standalone",  
6 - "background_color": "#0175C2",  
7 - "theme_color": "#0175C2",  
8 - "description": "Flutter PDF Demo.",  
9 - "orientation": "portrait-primary",  
10 - "prefer_related_applications": false,  
11 - "icons": [  
12 - {  
13 - "src": "icon-192.png",  
14 - "sizes": "192x192",  
15 - "type": "image/png"  
16 - },  
17 - {  
18 - "src": "icon-512.png",  
19 - "sizes": "512x512",  
20 - "type": "image/png"  
21 - }  
22 - ]  
23 -} 2 + "name": "Flutter PDF Demo",
  3 + "short_name": "Flutter PDF Demo",
  4 + "start_url": ".",
  5 + "display": "standalone",
  6 + "background_color": "#0175C2",
  7 + "theme_color": "#0175C2",
  8 + "description": "Flutter PDF Demo",
  9 + "orientation": "portrait-primary",
  10 + "prefer_related_applications": false,
  11 + "icons": [
  12 + {
  13 + "src": "icons/Icon-192.png",
  14 + "sizes": "192x192",
  15 + "type": "image/png"
  16 + },
  17 + {
  18 + "src": "icons/Icon-512.png",
  19 + "sizes": "512x512",
  20 + "type": "image/png"
  21 + },
  22 + {
  23 + "src": "icons/Icon-maskable-192.png",
  24 + "sizes": "192x192",
  25 + "type": "image/png",
  26 + "purpose": "maskable"
  27 + },
  28 + {
  29 + "src": "icons/Icon-maskable-512.png",
  30 + "sizes": "512x512",
  31 + "type": "image/png",
  32 + "purpose": "maskable"
  33 + }
  34 + ]
  35 +}
  1 +flutter/ephemeral/
  2 +
  3 +# Visual Studio user-specific files.
  4 +*.suo
  5 +*.user
  6 +*.userosscache
  7 +*.sln.docstates
  8 +
  9 +# Visual Studio build-related files.
  10 +x64/
  11 +x86/
  12 +
  13 +# Visual Studio cache files
  14 +# files ending in .cache can be ignored
  15 +*.[Cc]ache
  16 +# but keep track of directories ending in .cache
  17 +!*.[Cc]ache/
  1 +# Project-level configuration.
  2 +cmake_minimum_required(VERSION 3.14)
  3 +project(printing_demo LANGUAGES CXX)
  4 +
  5 +# The name of the executable created for the application. Change this to change
  6 +# the on-disk name of your application.
  7 +set(BINARY_NAME "printing_demo")
  8 +
  9 +# Explicitly opt in to modern CMake behaviors to avoid warnings with recent
  10 +# versions of CMake.
  11 +cmake_policy(SET CMP0063 NEW)
  12 +
  13 +# Define build configuration option.
  14 +get_property(IS_MULTICONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
  15 +if(IS_MULTICONFIG)
  16 + set(CMAKE_CONFIGURATION_TYPES "Debug;Profile;Release"
  17 + CACHE STRING "" FORCE)
  18 +else()
  19 + if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
  20 + set(CMAKE_BUILD_TYPE "Debug" CACHE
  21 + STRING "Flutter build mode" FORCE)
  22 + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
  23 + "Debug" "Profile" "Release")
  24 + endif()
  25 +endif()
  26 +# Define settings for the Profile build mode.
  27 +set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_RELEASE}")
  28 +set(CMAKE_SHARED_LINKER_FLAGS_PROFILE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE}")
  29 +set(CMAKE_C_FLAGS_PROFILE "${CMAKE_C_FLAGS_RELEASE}")
  30 +set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_RELEASE}")
  31 +
  32 +# Use Unicode for all projects.
  33 +add_definitions(-DUNICODE -D_UNICODE)
  34 +
  35 +# Compilation settings that should be applied to most targets.
  36 +#
  37 +# Be cautious about adding new options here, as plugins use this function by
  38 +# default. In most cases, you should add new options to specific targets instead
  39 +# of modifying this function.
  40 +function(APPLY_STANDARD_SETTINGS TARGET)
  41 + target_compile_features(${TARGET} PUBLIC cxx_std_17)
  42 + target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100")
  43 + target_compile_options(${TARGET} PRIVATE /EHsc)
  44 + target_compile_definitions(${TARGET} PRIVATE "_HAS_EXCEPTIONS=0")
  45 + target_compile_definitions(${TARGET} PRIVATE "$<$<CONFIG:Debug>:_DEBUG>")
  46 +endfunction()
  47 +
  48 +# Flutter library and tool build rules.
  49 +set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter")
  50 +add_subdirectory(${FLUTTER_MANAGED_DIR})
  51 +
  52 +# Application build; see runner/CMakeLists.txt.
  53 +add_subdirectory("runner")
  54 +
  55 +# Generated plugin build rules, which manage building the plugins and adding
  56 +# them to the application.
  57 +include(flutter/generated_plugins.cmake)
  58 +
  59 +
  60 +# === Installation ===
  61 +# Support files are copied into place next to the executable, so that it can
  62 +# run in place. This is done instead of making a separate bundle (as on Linux)
  63 +# so that building and running from within Visual Studio will work.
  64 +set(BUILD_BUNDLE_DIR "$<TARGET_FILE_DIR:${BINARY_NAME}>")
  65 +# Make the "install" step default, as it's required to run.
  66 +set(CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD 1)
  67 +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
  68 + set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE)
  69 +endif()
  70 +
  71 +set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data")
  72 +set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}")
  73 +
  74 +install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}"
  75 + COMPONENT Runtime)
  76 +
  77 +install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
  78 + COMPONENT Runtime)
  79 +
  80 +install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
  81 + COMPONENT Runtime)
  82 +
  83 +if(PLUGIN_BUNDLED_LIBRARIES)
  84 + install(FILES "${PLUGIN_BUNDLED_LIBRARIES}"
  85 + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
  86 + COMPONENT Runtime)
  87 +endif()
  88 +
  89 +# Fully re-copy the assets directory on each build to avoid having stale files
  90 +# from a previous install.
  91 +set(FLUTTER_ASSET_DIR_NAME "flutter_assets")
  92 +install(CODE "
  93 + file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\")
  94 + " COMPONENT Runtime)
  95 +install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}"
  96 + DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime)
  97 +
  98 +# Install the AOT library on non-Debug builds only.
  99 +install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
  100 + CONFIGURATIONS Profile;Release
  101 + COMPONENT Runtime)
  1 +# This file controls Flutter-level build steps. It should not be edited.
  2 +cmake_minimum_required(VERSION 3.14)
  3 +
  4 +set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral")
  5 +
  6 +# Configuration provided via flutter tool.
  7 +include(${EPHEMERAL_DIR}/generated_config.cmake)
  8 +
  9 +# TODO: Move the rest of this into files in ephemeral. See
  10 +# https://github.com/flutter/flutter/issues/57146.
  11 +set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper")
  12 +
  13 +# === Flutter Library ===
  14 +set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll")
  15 +
  16 +# Published to parent scope for install step.
  17 +set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE)
  18 +set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE)
  19 +set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE)
  20 +set(AOT_LIBRARY "${PROJECT_DIR}/build/windows/app.so" PARENT_SCOPE)
  21 +
  22 +list(APPEND FLUTTER_LIBRARY_HEADERS
  23 + "flutter_export.h"
  24 + "flutter_windows.h"
  25 + "flutter_messenger.h"
  26 + "flutter_plugin_registrar.h"
  27 + "flutter_texture_registrar.h"
  28 +)
  29 +list(TRANSFORM FLUTTER_LIBRARY_HEADERS PREPEND "${EPHEMERAL_DIR}/")
  30 +add_library(flutter INTERFACE)
  31 +target_include_directories(flutter INTERFACE
  32 + "${EPHEMERAL_DIR}"
  33 +)
  34 +target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}.lib")
  35 +add_dependencies(flutter flutter_assemble)
  36 +
  37 +# === Wrapper ===
  38 +list(APPEND CPP_WRAPPER_SOURCES_CORE
  39 + "core_implementations.cc"
  40 + "standard_codec.cc"
  41 +)
  42 +list(TRANSFORM CPP_WRAPPER_SOURCES_CORE PREPEND "${WRAPPER_ROOT}/")
  43 +list(APPEND CPP_WRAPPER_SOURCES_PLUGIN
  44 + "plugin_registrar.cc"
  45 +)
  46 +list(TRANSFORM CPP_WRAPPER_SOURCES_PLUGIN PREPEND "${WRAPPER_ROOT}/")
  47 +list(APPEND CPP_WRAPPER_SOURCES_APP
  48 + "flutter_engine.cc"
  49 + "flutter_view_controller.cc"
  50 +)
  51 +list(TRANSFORM CPP_WRAPPER_SOURCES_APP PREPEND "${WRAPPER_ROOT}/")
  52 +
  53 +# Wrapper sources needed for a plugin.
  54 +add_library(flutter_wrapper_plugin STATIC
  55 + ${CPP_WRAPPER_SOURCES_CORE}
  56 + ${CPP_WRAPPER_SOURCES_PLUGIN}
  57 +)
  58 +apply_standard_settings(flutter_wrapper_plugin)
  59 +set_target_properties(flutter_wrapper_plugin PROPERTIES
  60 + POSITION_INDEPENDENT_CODE ON)
  61 +set_target_properties(flutter_wrapper_plugin PROPERTIES
  62 + CXX_VISIBILITY_PRESET hidden)
  63 +target_link_libraries(flutter_wrapper_plugin PUBLIC flutter)
  64 +target_include_directories(flutter_wrapper_plugin PUBLIC
  65 + "${WRAPPER_ROOT}/include"
  66 +)
  67 +add_dependencies(flutter_wrapper_plugin flutter_assemble)
  68 +
  69 +# Wrapper sources needed for the runner.
  70 +add_library(flutter_wrapper_app STATIC
  71 + ${CPP_WRAPPER_SOURCES_CORE}
  72 + ${CPP_WRAPPER_SOURCES_APP}
  73 +)
  74 +apply_standard_settings(flutter_wrapper_app)
  75 +target_link_libraries(flutter_wrapper_app PUBLIC flutter)
  76 +target_include_directories(flutter_wrapper_app PUBLIC
  77 + "${WRAPPER_ROOT}/include"
  78 +)
  79 +add_dependencies(flutter_wrapper_app flutter_assemble)
  80 +
  81 +# === Flutter tool backend ===
  82 +# _phony_ is a non-existent file to force this command to run every time,
  83 +# since currently there's no way to get a full input/output list from the
  84 +# flutter tool.
  85 +set(PHONY_OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/_phony_")
  86 +set_source_files_properties("${PHONY_OUTPUT}" PROPERTIES SYMBOLIC TRUE)
  87 +add_custom_command(
  88 + OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS}
  89 + ${CPP_WRAPPER_SOURCES_CORE} ${CPP_WRAPPER_SOURCES_PLUGIN}
  90 + ${CPP_WRAPPER_SOURCES_APP}
  91 + ${PHONY_OUTPUT}
  92 + COMMAND ${CMAKE_COMMAND} -E env
  93 + ${FLUTTER_TOOL_ENVIRONMENT}
  94 + "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat"
  95 + windows-x64 $<CONFIG>
  96 + VERBATIM
  97 +)
  98 +add_custom_target(flutter_assemble DEPENDS
  99 + "${FLUTTER_LIBRARY}"
  100 + ${FLUTTER_LIBRARY_HEADERS}
  101 + ${CPP_WRAPPER_SOURCES_CORE}
  102 + ${CPP_WRAPPER_SOURCES_PLUGIN}
  103 + ${CPP_WRAPPER_SOURCES_APP}
  104 +)
  1 +//
  2 +// Generated file. Do not edit.
  3 +//
  4 +
  5 +// clang-format off
  6 +
  7 +#include "generated_plugin_registrant.h"
  8 +
  9 +#include <printing/printing_plugin.h>
  10 +#include <url_launcher_windows/url_launcher_windows.h>
  11 +
  12 +void RegisterPlugins(flutter::PluginRegistry* registry) {
  13 + PrintingPluginRegisterWithRegistrar(
  14 + registry->GetRegistrarForPlugin("PrintingPlugin"));
  15 + UrlLauncherWindowsRegisterWithRegistrar(
  16 + registry->GetRegistrarForPlugin("UrlLauncherWindows"));
  17 +}
  1 +//
  2 +// Generated file. Do not edit.
  3 +//
  4 +
  5 +// clang-format off
  6 +
  7 +#ifndef GENERATED_PLUGIN_REGISTRANT_
  8 +#define GENERATED_PLUGIN_REGISTRANT_
  9 +
  10 +#include <flutter/plugin_registry.h>
  11 +
  12 +// Registers Flutter plugins.
  13 +void RegisterPlugins(flutter::PluginRegistry* registry);
  14 +
  15 +#endif // GENERATED_PLUGIN_REGISTRANT_
  1 +#
  2 +# Generated file, do not edit.
  3 +#
  4 +
  5 +list(APPEND FLUTTER_PLUGIN_LIST
  6 + printing
  7 + url_launcher_windows
  8 +)
  9 +
  10 +list(APPEND FLUTTER_FFI_PLUGIN_LIST
  11 +)
  12 +
  13 +set(PLUGIN_BUNDLED_LIBRARIES)
  14 +
  15 +foreach(plugin ${FLUTTER_PLUGIN_LIST})
  16 + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin})
  17 + target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin)
  18 + list(APPEND PLUGIN_BUNDLED_LIBRARIES $<TARGET_FILE:${plugin}_plugin>)
  19 + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries})
  20 +endforeach(plugin)
  21 +
  22 +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST})
  23 + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin})
  24 + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries})
  25 +endforeach(ffi_plugin)
  1 +cmake_minimum_required(VERSION 3.14)
  2 +project(runner LANGUAGES CXX)
  3 +
  4 +# Define the application target. To change its name, change BINARY_NAME in the
  5 +# top-level CMakeLists.txt, not the value here, or `flutter run` will no longer
  6 +# work.
  7 +#
  8 +# Any new source files that you add to the application should be added here.
  9 +add_executable(${BINARY_NAME} WIN32
  10 + "flutter_window.cpp"
  11 + "main.cpp"
  12 + "utils.cpp"
  13 + "win32_window.cpp"
  14 + "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
  15 + "Runner.rc"
  16 + "runner.exe.manifest"
  17 +)
  18 +
  19 +# Apply the standard set of build settings. This can be removed for applications
  20 +# that need different build settings.
  21 +apply_standard_settings(${BINARY_NAME})
  22 +
  23 +# Add preprocessor definitions for the build version.
  24 +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION=\"${FLUTTER_VERSION}\"")
  25 +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MAJOR=${FLUTTER_VERSION_MAJOR}")
  26 +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MINOR=${FLUTTER_VERSION_MINOR}")
  27 +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_PATCH=${FLUTTER_VERSION_PATCH}")
  28 +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_BUILD=${FLUTTER_VERSION_BUILD}")
  29 +
  30 +# Disable Windows macros that collide with C++ standard library functions.
  31 +target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX")
  32 +
  33 +# Add dependency libraries and include directories. Add any application-specific
  34 +# dependencies here.
  35 +target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app)
  36 +target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}")
  37 +
  38 +# Run the Flutter tool portions of the build. This must not be removed.
  39 +add_dependencies(${BINARY_NAME} flutter_assemble)
  1 +// Microsoft Visual C++ generated resource script.
  2 +//
  3 +#pragma code_page(65001)
  4 +#include "resource.h"
  5 +
  6 +#define APSTUDIO_READONLY_SYMBOLS
  7 +/////////////////////////////////////////////////////////////////////////////
  8 +//
  9 +// Generated from the TEXTINCLUDE 2 resource.
  10 +//
  11 +#include "winres.h"
  12 +
  13 +/////////////////////////////////////////////////////////////////////////////
  14 +#undef APSTUDIO_READONLY_SYMBOLS
  15 +
  16 +/////////////////////////////////////////////////////////////////////////////
  17 +// English (United States) resources
  18 +
  19 +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
  20 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
  21 +
  22 +#ifdef APSTUDIO_INVOKED
  23 +/////////////////////////////////////////////////////////////////////////////
  24 +//
  25 +// TEXTINCLUDE
  26 +//
  27 +
  28 +1 TEXTINCLUDE
  29 +BEGIN
  30 + "resource.h\0"
  31 +END
  32 +
  33 +2 TEXTINCLUDE
  34 +BEGIN
  35 + "#include ""winres.h""\r\n"
  36 + "\0"
  37 +END
  38 +
  39 +3 TEXTINCLUDE
  40 +BEGIN
  41 + "\r\n"
  42 + "\0"
  43 +END
  44 +
  45 +#endif // APSTUDIO_INVOKED
  46 +
  47 +
  48 +/////////////////////////////////////////////////////////////////////////////
  49 +//
  50 +// Icon
  51 +//
  52 +
  53 +// Icon with lowest ID value placed first to ensure application icon
  54 +// remains consistent on all systems.
  55 +IDI_APP_ICON ICON "resources\\app_icon.ico"
  56 +
  57 +
  58 +/////////////////////////////////////////////////////////////////////////////
  59 +//
  60 +// Version
  61 +//
  62 +
  63 +#if defined(FLUTTER_VERSION_MAJOR) && defined(FLUTTER_VERSION_MINOR) && defined(FLUTTER_VERSION_PATCH) && defined(FLUTTER_VERSION_BUILD)
  64 +#define VERSION_AS_NUMBER FLUTTER_VERSION_MAJOR,FLUTTER_VERSION_MINOR,FLUTTER_VERSION_PATCH,FLUTTER_VERSION_BUILD
  65 +#else
  66 +#define VERSION_AS_NUMBER 1,0,0,0
  67 +#endif
  68 +
  69 +#if defined(FLUTTER_VERSION)
  70 +#define VERSION_AS_STRING FLUTTER_VERSION
  71 +#else
  72 +#define VERSION_AS_STRING "1.0.0"
  73 +#endif
  74 +
  75 +VS_VERSION_INFO VERSIONINFO
  76 + FILEVERSION VERSION_AS_NUMBER
  77 + PRODUCTVERSION VERSION_AS_NUMBER
  78 + FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
  79 +#ifdef _DEBUG
  80 + FILEFLAGS VS_FF_DEBUG
  81 +#else
  82 + FILEFLAGS 0x0L
  83 +#endif
  84 + FILEOS VOS__WINDOWS32
  85 + FILETYPE VFT_APP
  86 + FILESUBTYPE 0x0L
  87 +BEGIN
  88 + BLOCK "StringFileInfo"
  89 + BEGIN
  90 + BLOCK "040904e4"
  91 + BEGIN
  92 + VALUE "CompanyName", "net.nfet" "\0"
  93 + VALUE "FileDescription", "Flutter PDF Demo" "\0"
  94 + VALUE "FileVersion", VERSION_AS_STRING "\0"
  95 + VALUE "InternalName", "printing_demo" "\0"
  96 + VALUE "LegalCopyright", "Copyright (C) 2022 net.nfet. All rights reserved." "\0"
  97 + VALUE "OriginalFilename", "printing_demo.exe" "\0"
  98 + VALUE "ProductName", "Flutter PDF Demo" "\0"
  99 + VALUE "ProductVersion", VERSION_AS_STRING "\0"
  100 + END
  101 + END
  102 + BLOCK "VarFileInfo"
  103 + BEGIN
  104 + VALUE "Translation", 0x409, 1252
  105 + END
  106 +END
  107 +
  108 +#endif // English (United States) resources
  109 +/////////////////////////////////////////////////////////////////////////////
  110 +
  111 +
  112 +
  113 +#ifndef APSTUDIO_INVOKED
  114 +/////////////////////////////////////////////////////////////////////////////
  115 +//
  116 +// Generated from the TEXTINCLUDE 3 resource.
  117 +//
  118 +
  119 +
  120 +/////////////////////////////////////////////////////////////////////////////
  121 +#endif // not APSTUDIO_INVOKED
  1 +#include "flutter_window.h"
  2 +
  3 +#include <optional>
  4 +
  5 +#include "flutter/generated_plugin_registrant.h"
  6 +
  7 +FlutterWindow::FlutterWindow(const flutter::DartProject& project)
  8 + : project_(project) {}
  9 +
  10 +FlutterWindow::~FlutterWindow() {}
  11 +
  12 +bool FlutterWindow::OnCreate() {
  13 + if (!Win32Window::OnCreate()) {
  14 + return false;
  15 + }
  16 +
  17 + RECT frame = GetClientArea();
  18 +
  19 + // The size here must match the window dimensions to avoid unnecessary surface
  20 + // creation / destruction in the startup path.
  21 + flutter_controller_ = std::make_unique<flutter::FlutterViewController>(
  22 + frame.right - frame.left, frame.bottom - frame.top, project_);
  23 + // Ensure that basic setup of the controller was successful.
  24 + if (!flutter_controller_->engine() || !flutter_controller_->view()) {
  25 + return false;
  26 + }
  27 + RegisterPlugins(flutter_controller_->engine());
  28 + SetChildContent(flutter_controller_->view()->GetNativeWindow());
  29 + return true;
  30 +}
  31 +
  32 +void FlutterWindow::OnDestroy() {
  33 + if (flutter_controller_) {
  34 + flutter_controller_ = nullptr;
  35 + }
  36 +
  37 + Win32Window::OnDestroy();
  38 +}
  39 +
  40 +LRESULT
  41 +FlutterWindow::MessageHandler(HWND hwnd, UINT const message,
  42 + WPARAM const wparam,
  43 + LPARAM const lparam) noexcept {
  44 + // Give Flutter, including plugins, an opportunity to handle window messages.
  45 + if (flutter_controller_) {
  46 + std::optional<LRESULT> result =
  47 + flutter_controller_->HandleTopLevelWindowProc(hwnd, message, wparam,
  48 + lparam);
  49 + if (result) {
  50 + return *result;
  51 + }
  52 + }
  53 +
  54 + switch (message) {
  55 + case WM_FONTCHANGE:
  56 + flutter_controller_->engine()->ReloadSystemFonts();
  57 + break;
  58 + }
  59 +
  60 + return Win32Window::MessageHandler(hwnd, message, wparam, lparam);
  61 +}
  1 +#ifndef RUNNER_FLUTTER_WINDOW_H_
  2 +#define RUNNER_FLUTTER_WINDOW_H_
  3 +
  4 +#include <flutter/dart_project.h>
  5 +#include <flutter/flutter_view_controller.h>
  6 +
  7 +#include <memory>
  8 +
  9 +#include "win32_window.h"
  10 +
  11 +// A window that does nothing but host a Flutter view.
  12 +class FlutterWindow : public Win32Window {
  13 + public:
  14 + // Creates a new FlutterWindow hosting a Flutter view running |project|.
  15 + explicit FlutterWindow(const flutter::DartProject& project);
  16 + virtual ~FlutterWindow();
  17 +
  18 + protected:
  19 + // Win32Window:
  20 + bool OnCreate() override;
  21 + void OnDestroy() override;
  22 + LRESULT MessageHandler(HWND window, UINT const message, WPARAM const wparam,
  23 + LPARAM const lparam) noexcept override;
  24 +
  25 + private:
  26 + // The project to run.
  27 + flutter::DartProject project_;
  28 +
  29 + // The Flutter instance hosted by this window.
  30 + std::unique_ptr<flutter::FlutterViewController> flutter_controller_;
  31 +};
  32 +
  33 +#endif // RUNNER_FLUTTER_WINDOW_H_
  1 +#include <flutter/dart_project.h>
  2 +#include <flutter/flutter_view_controller.h>
  3 +#include <windows.h>
  4 +
  5 +#include "flutter_window.h"
  6 +#include "utils.h"
  7 +
  8 +int APIENTRY wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev,
  9 + _In_ wchar_t *command_line, _In_ int show_command) {
  10 + // Attach to console when present (e.g., 'flutter run') or create a
  11 + // new console when running with a debugger.
  12 + if (!::AttachConsole(ATTACH_PARENT_PROCESS) && ::IsDebuggerPresent()) {
  13 + CreateAndAttachConsole();
  14 + }
  15 +
  16 + // Initialize COM, so that it is available for use in the library and/or
  17 + // plugins.
  18 + ::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
  19 +
  20 + flutter::DartProject project(L"data");
  21 +
  22 + std::vector<std::string> command_line_arguments =
  23 + GetCommandLineArguments();
  24 +
  25 + project.set_dart_entrypoint_arguments(std::move(command_line_arguments));
  26 +
  27 + FlutterWindow window(project);
  28 + Win32Window::Point origin(10, 10);
  29 + Win32Window::Size size(1280, 720);
  30 + if (!window.CreateAndShow(L"Flutter PDF Demo", origin, size)) {
  31 + return EXIT_FAILURE;
  32 + }
  33 + window.SetQuitOnClose(true);
  34 +
  35 + ::MSG msg;
  36 + while (::GetMessage(&msg, nullptr, 0, 0)) {
  37 + ::TranslateMessage(&msg);
  38 + ::DispatchMessage(&msg);
  39 + }
  40 +
  41 + ::CoUninitialize();
  42 + return EXIT_SUCCESS;
  43 +}
  1 +//{{NO_DEPENDENCIES}}
  2 +// Microsoft Visual C++ generated include file.
  3 +// Used by Runner.rc
  4 +//
  5 +#define IDI_APP_ICON 101
  6 +
  7 +// Next default values for new objects
  8 +//
  9 +#ifdef APSTUDIO_INVOKED
  10 +#ifndef APSTUDIO_READONLY_SYMBOLS
  11 +#define _APS_NEXT_RESOURCE_VALUE 102
  12 +#define _APS_NEXT_COMMAND_VALUE 40001
  13 +#define _APS_NEXT_CONTROL_VALUE 1001
  14 +#define _APS_NEXT_SYMED_VALUE 101
  15 +#endif
  16 +#endif
No preview for this file type
  1 +<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  2 +<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
  3 + <application xmlns="urn:schemas-microsoft-com:asm.v3">
  4 + <windowsSettings>
  5 + <dpiAwareness xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">PerMonitorV2</dpiAwareness>
  6 + </windowsSettings>
  7 + </application>
  8 + <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
  9 + <application>
  10 + <!-- Windows 10 and Windows 11 -->
  11 + <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
  12 + <!-- Windows 8.1 -->
  13 + <supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
  14 + <!-- Windows 8 -->
  15 + <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
  16 + <!-- Windows 7 -->
  17 + <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
  18 + </application>
  19 + </compatibility>
  20 +</assembly>
  1 +#include "utils.h"
  2 +
  3 +#include <flutter_windows.h>
  4 +#include <io.h>
  5 +#include <stdio.h>
  6 +#include <windows.h>
  7 +
  8 +#include <iostream>
  9 +
  10 +void CreateAndAttachConsole() {
  11 + if (::AllocConsole()) {
  12 + FILE *unused;
  13 + if (freopen_s(&unused, "CONOUT$", "w", stdout)) {
  14 + _dup2(_fileno(stdout), 1);
  15 + }
  16 + if (freopen_s(&unused, "CONOUT$", "w", stderr)) {
  17 + _dup2(_fileno(stdout), 2);
  18 + }
  19 + std::ios::sync_with_stdio();
  20 + FlutterDesktopResyncOutputStreams();
  21 + }
  22 +}
  23 +
  24 +std::vector<std::string> GetCommandLineArguments() {
  25 + // Convert the UTF-16 command line arguments to UTF-8 for the Engine to use.
  26 + int argc;
  27 + wchar_t** argv = ::CommandLineToArgvW(::GetCommandLineW(), &argc);
  28 + if (argv == nullptr) {
  29 + return std::vector<std::string>();
  30 + }
  31 +
  32 + std::vector<std::string> command_line_arguments;
  33 +
  34 + // Skip the first argument as it's the binary name.
  35 + for (int i = 1; i < argc; i++) {
  36 + command_line_arguments.push_back(Utf8FromUtf16(argv[i]));
  37 + }
  38 +
  39 + ::LocalFree(argv);
  40 +
  41 + return command_line_arguments;
  42 +}
  43 +
  44 +std::string Utf8FromUtf16(const wchar_t* utf16_string) {
  45 + if (utf16_string == nullptr) {
  46 + return std::string();
  47 + }
  48 + int target_length = ::WideCharToMultiByte(
  49 + CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string,
  50 + -1, nullptr, 0, nullptr, nullptr);
  51 + std::string utf8_string;
  52 + if (target_length == 0 || target_length > utf8_string.max_size()) {
  53 + return utf8_string;
  54 + }
  55 + utf8_string.resize(target_length);
  56 + int converted_length = ::WideCharToMultiByte(
  57 + CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string,
  58 + -1, utf8_string.data(),
  59 + target_length, nullptr, nullptr);
  60 + if (converted_length == 0) {
  61 + return std::string();
  62 + }
  63 + return utf8_string;
  64 +}
  1 +#ifndef RUNNER_UTILS_H_
  2 +#define RUNNER_UTILS_H_
  3 +
  4 +#include <string>
  5 +#include <vector>
  6 +
  7 +// Creates a console for the process, and redirects stdout and stderr to
  8 +// it for both the runner and the Flutter library.
  9 +void CreateAndAttachConsole();
  10 +
  11 +// Takes a null-terminated wchar_t* encoded in UTF-16 and returns a std::string
  12 +// encoded in UTF-8. Returns an empty std::string on failure.
  13 +std::string Utf8FromUtf16(const wchar_t* utf16_string);
  14 +
  15 +// Gets the command line arguments passed in as a std::vector<std::string>,
  16 +// encoded in UTF-8. Returns an empty std::vector<std::string> on failure.
  17 +std::vector<std::string> GetCommandLineArguments();
  18 +
  19 +#endif // RUNNER_UTILS_H_
  1 +#include "win32_window.h"
  2 +
  3 +#include <flutter_windows.h>
  4 +
  5 +#include "resource.h"
  6 +
  7 +namespace {
  8 +
  9 +constexpr const wchar_t kWindowClassName[] = L"FLUTTER_RUNNER_WIN32_WINDOW";
  10 +
  11 +// The number of Win32Window objects that currently exist.
  12 +static int g_active_window_count = 0;
  13 +
  14 +using EnableNonClientDpiScaling = BOOL __stdcall(HWND hwnd);
  15 +
  16 +// Scale helper to convert logical scaler values to physical using passed in
  17 +// scale factor
  18 +int Scale(int source, double scale_factor) {
  19 + return static_cast<int>(source * scale_factor);
  20 +}
  21 +
  22 +// Dynamically loads the |EnableNonClientDpiScaling| from the User32 module.
  23 +// This API is only needed for PerMonitor V1 awareness mode.
  24 +void EnableFullDpiSupportIfAvailable(HWND hwnd) {
  25 + HMODULE user32_module = LoadLibraryA("User32.dll");
  26 + if (!user32_module) {
  27 + return;
  28 + }
  29 + auto enable_non_client_dpi_scaling =
  30 + reinterpret_cast<EnableNonClientDpiScaling*>(
  31 + GetProcAddress(user32_module, "EnableNonClientDpiScaling"));
  32 + if (enable_non_client_dpi_scaling != nullptr) {
  33 + enable_non_client_dpi_scaling(hwnd);
  34 + FreeLibrary(user32_module);
  35 + }
  36 +}
  37 +
  38 +} // namespace
  39 +
  40 +// Manages the Win32Window's window class registration.
  41 +class WindowClassRegistrar {
  42 + public:
  43 + ~WindowClassRegistrar() = default;
  44 +
  45 + // Returns the singleton registar instance.
  46 + static WindowClassRegistrar* GetInstance() {
  47 + if (!instance_) {
  48 + instance_ = new WindowClassRegistrar();
  49 + }
  50 + return instance_;
  51 + }
  52 +
  53 + // Returns the name of the window class, registering the class if it hasn't
  54 + // previously been registered.
  55 + const wchar_t* GetWindowClass();
  56 +
  57 + // Unregisters the window class. Should only be called if there are no
  58 + // instances of the window.
  59 + void UnregisterWindowClass();
  60 +
  61 + private:
  62 + WindowClassRegistrar() = default;
  63 +
  64 + static WindowClassRegistrar* instance_;
  65 +
  66 + bool class_registered_ = false;
  67 +};
  68 +
  69 +WindowClassRegistrar* WindowClassRegistrar::instance_ = nullptr;
  70 +
  71 +const wchar_t* WindowClassRegistrar::GetWindowClass() {
  72 + if (!class_registered_) {
  73 + WNDCLASS window_class{};
  74 + window_class.hCursor = LoadCursor(nullptr, IDC_ARROW);
  75 + window_class.lpszClassName = kWindowClassName;
  76 + window_class.style = CS_HREDRAW | CS_VREDRAW;
  77 + window_class.cbClsExtra = 0;
  78 + window_class.cbWndExtra = 0;
  79 + window_class.hInstance = GetModuleHandle(nullptr);
  80 + window_class.hIcon =
  81 + LoadIcon(window_class.hInstance, MAKEINTRESOURCE(IDI_APP_ICON));
  82 + window_class.hbrBackground = 0;
  83 + window_class.lpszMenuName = nullptr;
  84 + window_class.lpfnWndProc = Win32Window::WndProc;
  85 + RegisterClass(&window_class);
  86 + class_registered_ = true;
  87 + }
  88 + return kWindowClassName;
  89 +}
  90 +
  91 +void WindowClassRegistrar::UnregisterWindowClass() {
  92 + UnregisterClass(kWindowClassName, nullptr);
  93 + class_registered_ = false;
  94 +}
  95 +
  96 +Win32Window::Win32Window() {
  97 + ++g_active_window_count;
  98 +}
  99 +
  100 +Win32Window::~Win32Window() {
  101 + --g_active_window_count;
  102 + Destroy();
  103 +}
  104 +
  105 +bool Win32Window::CreateAndShow(const std::wstring& title,
  106 + const Point& origin,
  107 + const Size& size) {
  108 + Destroy();
  109 +
  110 + const wchar_t* window_class =
  111 + WindowClassRegistrar::GetInstance()->GetWindowClass();
  112 +
  113 + const POINT target_point = {static_cast<LONG>(origin.x),
  114 + static_cast<LONG>(origin.y)};
  115 + HMONITOR monitor = MonitorFromPoint(target_point, MONITOR_DEFAULTTONEAREST);
  116 + UINT dpi = FlutterDesktopGetDpiForMonitor(monitor);
  117 + double scale_factor = dpi / 96.0;
  118 +
  119 + HWND window = CreateWindow(
  120 + window_class, title.c_str(), WS_OVERLAPPEDWINDOW | WS_VISIBLE,
  121 + Scale(origin.x, scale_factor), Scale(origin.y, scale_factor),
  122 + Scale(size.width, scale_factor), Scale(size.height, scale_factor),
  123 + nullptr, nullptr, GetModuleHandle(nullptr), this);
  124 +
  125 + if (!window) {
  126 + return false;
  127 + }
  128 +
  129 + return OnCreate();
  130 +}
  131 +
  132 +// static
  133 +LRESULT CALLBACK Win32Window::WndProc(HWND const window,
  134 + UINT const message,
  135 + WPARAM const wparam,
  136 + LPARAM const lparam) noexcept {
  137 + if (message == WM_NCCREATE) {
  138 + auto window_struct = reinterpret_cast<CREATESTRUCT*>(lparam);
  139 + SetWindowLongPtr(window, GWLP_USERDATA,
  140 + reinterpret_cast<LONG_PTR>(window_struct->lpCreateParams));
  141 +
  142 + auto that = static_cast<Win32Window*>(window_struct->lpCreateParams);
  143 + EnableFullDpiSupportIfAvailable(window);
  144 + that->window_handle_ = window;
  145 + } else if (Win32Window* that = GetThisFromHandle(window)) {
  146 + return that->MessageHandler(window, message, wparam, lparam);
  147 + }
  148 +
  149 + return DefWindowProc(window, message, wparam, lparam);
  150 +}
  151 +
  152 +LRESULT
  153 +Win32Window::MessageHandler(HWND hwnd,
  154 + UINT const message,
  155 + WPARAM const wparam,
  156 + LPARAM const lparam) noexcept {
  157 + switch (message) {
  158 + case WM_DESTROY:
  159 + window_handle_ = nullptr;
  160 + Destroy();
  161 + if (quit_on_close_) {
  162 + PostQuitMessage(0);
  163 + }
  164 + return 0;
  165 +
  166 + case WM_DPICHANGED: {
  167 + auto newRectSize = reinterpret_cast<RECT*>(lparam);
  168 + LONG newWidth = newRectSize->right - newRectSize->left;
  169 + LONG newHeight = newRectSize->bottom - newRectSize->top;
  170 +
  171 + SetWindowPos(hwnd, nullptr, newRectSize->left, newRectSize->top, newWidth,
  172 + newHeight, SWP_NOZORDER | SWP_NOACTIVATE);
  173 +
  174 + return 0;
  175 + }
  176 + case WM_SIZE: {
  177 + RECT rect = GetClientArea();
  178 + if (child_content_ != nullptr) {
  179 + // Size and position the child window.
  180 + MoveWindow(child_content_, rect.left, rect.top, rect.right - rect.left,
  181 + rect.bottom - rect.top, TRUE);
  182 + }
  183 + return 0;
  184 + }
  185 +
  186 + case WM_ACTIVATE:
  187 + if (child_content_ != nullptr) {
  188 + SetFocus(child_content_);
  189 + }
  190 + return 0;
  191 + }
  192 +
  193 + return DefWindowProc(window_handle_, message, wparam, lparam);
  194 +}
  195 +
  196 +void Win32Window::Destroy() {
  197 + OnDestroy();
  198 +
  199 + if (window_handle_) {
  200 + DestroyWindow(window_handle_);
  201 + window_handle_ = nullptr;
  202 + }
  203 + if (g_active_window_count == 0) {
  204 + WindowClassRegistrar::GetInstance()->UnregisterWindowClass();
  205 + }
  206 +}
  207 +
  208 +Win32Window* Win32Window::GetThisFromHandle(HWND const window) noexcept {
  209 + return reinterpret_cast<Win32Window*>(
  210 + GetWindowLongPtr(window, GWLP_USERDATA));
  211 +}
  212 +
  213 +void Win32Window::SetChildContent(HWND content) {
  214 + child_content_ = content;
  215 + SetParent(content, window_handle_);
  216 + RECT frame = GetClientArea();
  217 +
  218 + MoveWindow(content, frame.left, frame.top, frame.right - frame.left,
  219 + frame.bottom - frame.top, true);
  220 +
  221 + SetFocus(child_content_);
  222 +}
  223 +
  224 +RECT Win32Window::GetClientArea() {
  225 + RECT frame;
  226 + GetClientRect(window_handle_, &frame);
  227 + return frame;
  228 +}
  229 +
  230 +HWND Win32Window::GetHandle() {
  231 + return window_handle_;
  232 +}
  233 +
  234 +void Win32Window::SetQuitOnClose(bool quit_on_close) {
  235 + quit_on_close_ = quit_on_close;
  236 +}
  237 +
  238 +bool Win32Window::OnCreate() {
  239 + // No-op; provided for subclasses.
  240 + return true;
  241 +}
  242 +
  243 +void Win32Window::OnDestroy() {
  244 + // No-op; provided for subclasses.
  245 +}
  1 +#ifndef RUNNER_WIN32_WINDOW_H_
  2 +#define RUNNER_WIN32_WINDOW_H_
  3 +
  4 +#include <windows.h>
  5 +
  6 +#include <functional>
  7 +#include <memory>
  8 +#include <string>
  9 +
  10 +// A class abstraction for a high DPI-aware Win32 Window. Intended to be
  11 +// inherited from by classes that wish to specialize with custom
  12 +// rendering and input handling
  13 +class Win32Window {
  14 + public:
  15 + struct Point {
  16 + unsigned int x;
  17 + unsigned int y;
  18 + Point(unsigned int x, unsigned int y) : x(x), y(y) {}
  19 + };
  20 +
  21 + struct Size {
  22 + unsigned int width;
  23 + unsigned int height;
  24 + Size(unsigned int width, unsigned int height)
  25 + : width(width), height(height) {}
  26 + };
  27 +
  28 + Win32Window();
  29 + virtual ~Win32Window();
  30 +
  31 + // Creates and shows a win32 window with |title| and position and size using
  32 + // |origin| and |size|. New windows are created on the default monitor. Window
  33 + // sizes are specified to the OS in physical pixels, hence to ensure a
  34 + // consistent size to will treat the width height passed in to this function
  35 + // as logical pixels and scale to appropriate for the default monitor. Returns
  36 + // true if the window was created successfully.
  37 + bool CreateAndShow(const std::wstring& title,
  38 + const Point& origin,
  39 + const Size& size);
  40 +
  41 + // Release OS resources associated with window.
  42 + void Destroy();
  43 +
  44 + // Inserts |content| into the window tree.
  45 + void SetChildContent(HWND content);
  46 +
  47 + // Returns the backing Window handle to enable clients to set icon and other
  48 + // window properties. Returns nullptr if the window has been destroyed.
  49 + HWND GetHandle();
  50 +
  51 + // If true, closing this window will quit the application.
  52 + void SetQuitOnClose(bool quit_on_close);
  53 +
  54 + // Return a RECT representing the bounds of the current client area.
  55 + RECT GetClientArea();
  56 +
  57 + protected:
  58 + // Processes and route salient window messages for mouse handling,
  59 + // size change and DPI. Delegates handling of these to member overloads that
  60 + // inheriting classes can handle.
  61 + virtual LRESULT MessageHandler(HWND window,
  62 + UINT const message,
  63 + WPARAM const wparam,
  64 + LPARAM const lparam) noexcept;
  65 +
  66 + // Called when CreateAndShow is called, allowing subclass window-related
  67 + // setup. Subclasses should return false if setup fails.
  68 + virtual bool OnCreate();
  69 +
  70 + // Called when Destroy is called.
  71 + virtual void OnDestroy();
  72 +
  73 + private:
  74 + friend class WindowClassRegistrar;
  75 +
  76 + // OS callback called by message pump. Handles the WM_NCCREATE message which
  77 + // is passed when the non-client area is being created and enables automatic
  78 + // non-client DPI scaling so that the non-client area automatically
  79 + // responsponds to changes in DPI. All other messages are handled by
  80 + // MessageHandler.
  81 + static LRESULT CALLBACK WndProc(HWND const window,
  82 + UINT const message,
  83 + WPARAM const wparam,
  84 + LPARAM const lparam) noexcept;
  85 +
  86 + // Retrieves a class instance pointer for |window|
  87 + static Win32Window* GetThisFromHandle(HWND const window) noexcept;
  88 +
  89 + bool quit_on_close_ = false;
  90 +
  91 + // window handle for top level window.
  92 + HWND window_handle_ = nullptr;
  93 +
  94 + // window handle for hosted content.
  95 + HWND child_content_ = nullptr;
  96 +};
  97 +
  98 +#endif // RUNNER_WIN32_WINDOW_H_
@@ -14,6 +14,10 @@ See an interactive demo here: <https://davbfr.github.io/dart_pdf/>. @@ -14,6 +14,10 @@ See an interactive demo here: <https://davbfr.github.io/dart_pdf/>.
14 <img alt="Example document" src="https://raw.githubusercontent.com/DavBfr/dart_pdf/master/pdf/example.jpg"> 14 <img alt="Example document" src="https://raw.githubusercontent.com/DavBfr/dart_pdf/master/pdf/example.jpg">
15 </a> 15 </a>
16 16
  17 +The source code for a full demo that can run on any Flutter target, and how to build,
  18 +it can be found here:
  19 +<https://github.com/DavBfr/dart_pdf/tree/master/demo/>
  20 +
17 Use the `printing` package <https://pub.dev/packages/printing> 21 Use the `printing` package <https://pub.dev/packages/printing>
18 for full flutter print and share operation. 22 for full flutter print and share operation.
19 23