<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Shrishti Gupta on Medium]]></title>
        <description><![CDATA[Stories by Shrishti Gupta on Medium]]></description>
        <link>https://medium.com/@shrishti2001gupta?source=rss-72d74e3bbfb7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*rs4Q3JGETFEse-R3</url>
            <title>Stories by Shrishti Gupta on Medium</title>
            <link>https://medium.com/@shrishti2001gupta?source=rss-72d74e3bbfb7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 17:23:58 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@shrishti2001gupta/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to print/save the flutter application screen as pdf?]]></title>
            <link>https://shrishti2001gupta.medium.com/how-to-print-save-the-flutter-application-screen-as-pdf-5abbbe9fe666?source=rss-72d74e3bbfb7------2</link>
            <guid isPermaLink="false">https://medium.com/p/5abbbe9fe666</guid>
            <category><![CDATA[flutter-widget]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[dart]]></category>
            <category><![CDATA[flutter-app-development]]></category>
            <category><![CDATA[vscode]]></category>
            <dc:creator><![CDATA[Shrishti Gupta]]></dc:creator>
            <pubDate>Thu, 23 Dec 2021 09:31:12 GMT</pubDate>
            <atom:updated>2021-12-23T09:31:12.083Z</atom:updated>
            <content:encoded><![CDATA[<p>Hey flutter folks.!</p><p>Ever wondered how can we export a flutter application screen as a pdf? Let&#39;s get started.</p><p>First of all, we need to add two packages to our pubspec.yaml file.</p><blockquote>pdf: ^3.6.5</blockquote><blockquote>printing: ^5.6.6</blockquote><p><strong>They provide android, ios as well as web support.</strong></p><p>This is the simple screen layout that we will use to demo the function</p><pre>import &#39;package:flutter/material.dart&#39;;</pre><pre>class ScreenToPdf extends StatelessWidget {</pre><pre>@override</pre><pre>Widget build(BuildContext context) {</pre><pre>return Scaffold(</pre><pre>appBar: AppBar(</pre><pre>title: const Text(&#39;Screen to PDF&#39;),</pre><pre>),</pre><pre>body: Center(</pre><pre>child: Column(</pre><pre>mainAxisAlignment: MainAxisAlignment.center,</pre><pre>children: [</pre><pre>Image.network(</pre><pre>&#39;https://picsum.photos/250?image=9&#39;,</pre><pre>height: 200,</pre><pre>width: 200,</pre><pre>),</pre><pre>const SizedBox(</pre><pre>height: 20,</pre><pre>),</pre><pre>ElevatedButton(</pre><pre>child: const Text(&#39;Screen to PDF&#39;),</pre><pre>onPressed: () {},</pre><pre>),</pre><pre>const Text(&#39;Printing the data from the screen to PDF&#39;),</pre><pre>],</pre><pre>),</pre><pre>),</pre><pre>);</pre><pre>}</pre><pre>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/738/1*UK8bKqxhsTEJcpTWvy_oKA.jpeg" /><figcaption>This is the basic layout</figcaption></figure><p><strong>Import the necessary dart files:</strong></p><blockquote>import ‘package:pdf/pdf.dart’;</blockquote><blockquote>import ‘package:pdf/widgets.dart ‘ as pw;</blockquote><blockquote>import ‘package:printing/printing.dart’;</blockquote><p><strong>Now declare a global key as shown below:</strong></p><blockquote>final GlobalKey&lt;State&lt;StatefulWidget&gt;&gt; _printKey = GlobalKey();</blockquote><p><strong>Wrap the widget tree with the Repaint Boundary and pass the key as the parameter:</strong></p><pre>Widget build(BuildContext context) {<br>return RepaintBoundary(<br>key: _printKey,<br>child: Scaffold(...)<br>);}</pre><p>_printScreen() is the function that will export the screen as pdf and we can either print it or save it as a pdf. Here pass your global key as a parameter and call the _printScreen() in the elevated button’s onPressed method.</p><pre>void _printScreen() async {</pre><pre>Printing.layoutPdf(onLayout: (PdfPageFormat format) async {</pre><pre>final doc = pw.Document();</pre><pre>final image = await WidgetWraper.fromKey(</pre><pre><strong>key: _printKey,</strong></pre><pre>pixelRatio: 2.0,</pre><pre>);</pre><pre>doc.addPage(pw.Page(</pre><pre>pageFormat: format,</pre><pre>build: (pw.Context context) {</pre><pre>return pw.Center(</pre><pre>child: pw.Expanded(</pre><pre>child: pw.Image(image),</pre><pre>),</pre><pre>);</pre><pre>}));<br>return doc.save();</pre><pre>});</pre><pre>}</pre><p><strong>Video showing the usage of the application</strong></p><p><a href="https://drive.google.com/file/d/1ei6pXBoQYj7-uWgFXK4r8p8FBRfKTVEX/view?usp=sharing">WhatsApp Video 2021-12-23 at 2.14.07 PM.mp4</a></p><p><strong>This is how the saved pdf looks:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/738/1*Z30bp3fJglecDrvAl-mJXg.jpeg" /><figcaption>Downloaded pdf</figcaption></figure><p><strong>Limitations:</strong></p><ul><li>This method will not work if any media component such as Youtube Player, Video player, etc are present in the widget tree as they can’t be rendered in a pdf. Make sure you are wrapping only the widget tree where any media component is not present.</li></ul><p><strong>Source code for this project:</strong></p><p><a href="https://github.com/shrishti08/ScreenToPdf">GitHub - shrishti08/ScreenToPdf: A flutter application to show ow to print/save the flutter application screen as pdf?</a></p><blockquote>If you like it then please support me by clapping and following me on medium. <strong>Thank you for reading!</strong></blockquote><p>You can also connect with me on Linkedin or can email me.</p><p><a href="http://linkedin.com/in/sgshrishti">LinkedIn</a></p><p><a href="http://shrishti2001gupta@gmail.com/">Gmail</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5abbbe9fe666" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[Guide] Flutter for Beginners]]></title>
            <link>https://shrishti2001gupta.medium.com/guide-flutter-for-beginners-add3f4f4d09f?source=rss-72d74e3bbfb7------2</link>
            <guid isPermaLink="false">https://medium.com/p/add3f4f4d09f</guid>
            <category><![CDATA[flutter-app-development]]></category>
            <category><![CDATA[app-development]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[android-app-development]]></category>
            <dc:creator><![CDATA[Shrishti Gupta]]></dc:creator>
            <pubDate>Fri, 21 May 2021 02:14:18 GMT</pubDate>
            <atom:updated>2021-08-15T11:42:46.140Z</atom:updated>
            <content:encoded><![CDATA[<h4>Kickstart your flutter journey with these free courses</h4><figure><img alt="Flutter for beginners by Shrishti Gupta" src="https://cdn-images-1.medium.com/max/1024/1*kSw-njRsFwVlqbTElIX8oQ.jpeg" /></figure><p>I started my flutter journey a few months back. I came across a blog and read about flutter and how useful and easy it is to build beautiful apps.</p><p><strong>WHY FLUTTER?</strong></p><p>The most fascinating feature of the flutter is that it provides a common platform to build both android and ios applications as well as web applications with Flutter 2.0 using a single codebase i.e. Dart(a new programming language developed by Google) which is very easy to grab if someone has prior knowledge of any programming language. Flutter provides access to hot reload and hot refresh which makes it super efficient and fast. You can see the changes you’ve made instantly just by saving it and need not run the application from scratch which sometimes takes more than 5–7 mins. Flutter team comes from the web development side so they incorporated many features of web dev into flutter which gave us so many customized widgets to create beautiful UI designs.</p><p><strong>HOW TO KICKSTART YOUR JOURNEY?</strong></p><p>The flutter team provides full documentation on using and learning flutter. It has step by step installation guide for windows, macOS as well as Linux. You can use both Android Studio or Visual Studio Code to make your applications. I prefer Android Studio because in the future you have to use Android Studio as VS Code does not have all the features one needs. There are many blogs and youtube videos for learning flutter. Flutter team created its series of learning flutter on youtube. (I will give links to all resources at the end.)</p><p><em>THE MISTAKES I MADE DURING MY LEARNING </em>which I don’t want anyone to repeat is</p><p>that I started setting up everything on my own without any help from any video or anything which leads to so much wastage of time as it is difficult to understand the problem and then solve the errors. As a beginner, one should always seek help from a guide. The second mistake was that I wasted a lot of time learning dart. You don’t need to learn dart independently as it is very easy and most of the concepts are the same. The course which you will choose to learn is enough to make you learn the syntax and everything you need to learn in the Dart.</p><p><strong>RESOURCES</strong></p><p>After going through so many courses and youtube videos the ones which I found the best are:</p><ol><li>This is by far the best course for beginners. You could buy it on Udemy but if it is something that you can’t afford, contact me at my <a href="https://www.linkedin.com/in/sgshrishti/">LinkedIn Profile</a> or by email(srishti2001gupta@gmail.com) and I will provide you with the free version of this course.</li></ol><p><a href="https://www.udemy.com/course/flutter-bootcamp-with-dart/">The Complete 2021 Flutter Development Bootcamp with Dart</a></p><p>Github link for course resources:</p><p><a href="https://github.com/londonappbrewery/Flutter-Course-Resources/">GitHub - londonappbrewery/Flutter-Course-Resources: Learn to Code While Building Apps - The Complete Flutter Development Bootcamp</a></p><p>You could check out the ‘Widget of the Week’ playlist uploaded by Flutter Official YouTube Channel</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fb_sQ9bMltGU%3Flist%3DPLjxrf2q8roU23XGwz3Km7sQZFTdB996iG&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Db_sQ9bMltGU&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2Fb_sQ9bMltGU%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e166bb8482d7f3d7f349be321af367d9/href">https://medium.com/media/e166bb8482d7f3d7f349be321af367d9/href</a></iframe><p>Or you can consult the playlist uploaded by The Net Ninja (764k followers) which focuses on beginners.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F1ukSR1GRtMU%3Flist%3DPL4cUxeGkcC9jLYyp2Aoh6hcWuxFDX6PBJ&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D1ukSR1GRtMU&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F1ukSR1GRtMU%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/04383a976ded6c26af00904498fbd44e/href">https://medium.com/media/04383a976ded6c26af00904498fbd44e/href</a></iframe><p>Thank you for reading :) Please connect with me on <a href="https://www.linkedin.com/in/sgshrishti/">LinkedIn</a> or if you have any queries, don’t hesitate to reach me at my email id: (srishti2001gupta@gmail.com)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=add3f4f4d09f" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>