{"id":2113,"date":"2022-01-06T12:00:23","date_gmt":"2022-01-06T20:00:23","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/surface-duo\/?p=2113"},"modified":"2021-12-23T11:15:03","modified_gmt":"2021-12-23T19:15:03","slug":"happy-new-year-2022","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/surface-duo\/happy-new-year-2022\/","title":{"rendered":"Happy Two Year"},"content":{"rendered":"<p>\n  Hello developers!\n<\/p>\n<p>\n  Welcome to 2022 \u2013 a great year to be developing for two screens! To kick off the new year we\u2019re going to do a quick recap of all the two screen enhanced components \u2013 across developer platforms \u2013 that can help you get started quickly with dual-screen and foldable support, while also providing great single-screen experiences on phones or larger-screen devices.\n<\/p>\n<h2>Two screen native controls<\/h2>\n<p>\n  Among our rich library of dual-screen controls, the <a href=\"https:\/\/docs.microsoft.com\/en-us\/dual-screen\/android\/api-reference\/dualscreen-library\/layouts\/surfaceduo-layout\">FoldableLayout component<\/a> provides an easy way for Kotlin and Java developers to build an adaptive user interface without having to write a lot of custom code. You can find both <a href=\"https:\/\/github.com\/microsoft\/surface-duo-sdk-samples-kotlin\">simple samples<\/a> and a <a href=\"https:\/\/github.com\/microsoft\/surface-duo-dual-screen-experience-example\">real-world app example<\/a> on GitHub.\n<\/p>\n<p>\n  <img decoding=\"async\" width=\"800\" height=\"321\" src=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-6.png\" class=\"wp-image-2114\" srcset=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-6.png 800w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-6-300x120.png 300w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-6-768x308.png 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/>\n<\/p>\n<h2>TwoPaneLayout for Jetpack Compose<\/h2>\n<p>\n  Jetpack Compose developers can add the Microsoft <a href=\"https:\/\/docs.microsoft.com\/dual-screen\/android\/jetpack\/compose\/two-pane-layout\">TwoPaneLayout<\/a> to their apps. There are many code examples in our <a href=\"https:\/\/github.com\/microsoft\/surface-duo-compose-samples\">Jetpack Compose Samples GitHub repo<\/a>, including simple guidance as well as the NavigationRail demo which combines a number of components into a well-designed dual-screen user experience:\n<\/p>\n<p>  <img decoding=\"async\" width=\"800\" height=\"321\" src=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-picture-containing-text-electronics-display-s.png\" class=\"wp-image-2115\" alt=\"A picture containing text, electronics, display, screenshot\n\nDescription automatically generated\" srcset=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-picture-containing-text-electronics-display-s.png 800w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-picture-containing-text-electronics-display-s-300x120.png 300w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-picture-containing-text-electronics-display-s-768x308.png 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/>\n<\/p>\n<h2>TwoPane widget for Flutter<\/h2>\n<p>\n  Flutter developers can try out the <a href=\"https:\/\/docs.microsoft.com\/dual-screen\/flutter\/twopane-widget\">TwoPane widget<\/a> that the developer experience team is working on. Follow these <a href=\"https:\/\/docs.microsoft.com\/dual-screen\/flutter\/\">instructions<\/a> to set up your Flutter project for dual-screen support.\n<\/p>\n<p>  <img decoding=\"async\" width=\"400\" height=\"321\" src=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-close-up-of-a-smartphone-description-automatica.png\" class=\"wp-image-2116\" alt=\"A close-up of a smartphone\n\nDescription automatically generated with low confidence\" srcset=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-close-up-of-a-smartphone-description-automatica.png 400w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/a-close-up-of-a-smartphone-description-automatica-300x241.png 300w\" sizes=\"(max-width: 400px) 100vw, 400px\" \/>\n<\/p>\n<h2>TwoPaneView for .NET<\/h2>\n<p><a href=\"https:\/\/docs.microsoft.com\/dual-screen\/xamarin\/twopaneview\">Xamarin<\/a> and <a href=\"https:\/\/platform.uno\/docs\/articles\/implemented\/windows-ui-xaml-controls-twopaneview.html\">Uno Platform<\/a> developers both have access to the TwoPaneView component using C# and XAML.\n<\/p>\n<p>\n  <img decoding=\"async\" width=\"400\" height=\"311\" src=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-7.png\" class=\"wp-image-2117\" srcset=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-7.png 400w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/word-image-7-300x233.png 300w\" sizes=\"(max-width: 400px) 100vw, 400px\" \/>\n<\/p>\n<h2>Two viewport segments in Edge<\/h2>\n<p>\n  Web developers can take advantage of the <a href=\"https:\/\/docs.microsoft.com\/dual-screen\/web\/css-viewport-segments\">viewport segments CSS media query<\/a> to build dual-screen aware layouts that work when Edge is spanned over two screens. You can view a <a href=\"https:\/\/conceptdev.github.io\/web-samples\/dual-screen-css\/boxes-future.html\">demo online<\/a> (using browser developer tools) and try out <a href=\"https:\/\/github.com\/foldable-devices\/demos\">these complete samples<\/a> which include a battleship game, a photo gallery, and a news reading experience.\n<\/p>\n<p>\n  <img decoding=\"async\" width=\"921\" height=\"670\" src=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/graphical-user-interface-application-word-descr.png\" class=\"wp-image-2118\" alt=\"Graphical user interface, application, Word\n\nDescription automatically generated\" srcset=\"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/graphical-user-interface-application-word-descr.png 921w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/graphical-user-interface-application-word-descr-300x218.png 300w, https:\/\/devblogs.microsoft.com\/surface-duo\/wp-content\/uploads\/sites\/53\/2021\/12\/graphical-user-interface-application-word-descr-768x559.png 768w\" sizes=\"(max-width: 921px) 100vw, 921px\" \/>\n<\/p>\n<h2>\n  Resources and feedback\u00a0\n<\/h2>\n<p>\n  We\u2019d love to hear about your plans for building dual-screen and fold-aware apps in 2022 \u2013 use the\u202f<a href=\"http:\/\/aka.ms\/SurfaceDuoSDK-Feedback\" target=\"_blank\" rel=\"noopener\">feedback forum<\/a>\u202for message us on Twitter\u202f<a href=\"https:\/\/twitter.com\/surfaceduodev\" target=\"_blank\" rel=\"noopener\">@surfaceduodev<\/a>.\u202f\n<\/p>\n<p>\n  Finally, please join us for our\u00a0<a href=\"https:\/\/twitch.tv\/surfaceduodev\" target=\"_blank\" rel=\"noopener\">dual screen developer livestream<\/a>\u00a0at 11am (Pacific time) each Friday \u2013 mark it in your calendar and check out the\u00a0<a href=\"https:\/\/www.youtube.com\/channel\/UClGu9QLtPNz8OdddBfhZXPA\" target=\"_blank\" rel=\"noopener\">archives on YouTube<\/a>.\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hello developers! Welcome to 2022 \u2013 a great year to be developing for two screens! To kick off the new year we\u2019re going to do a quick recap of all the two screen enhanced components \u2013 across developer platforms \u2013 that can help you get started quickly with dual-screen and foldable support, while also providing [&hellip;]<\/p>\n","protected":false},"author":570,"featured_media":2121,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[693,692,706,473],"class_list":["post-2113","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-surface-duo-sdk","tag-flutter","tag-jetpack-compose","tag-jetpack-window-manager","tag-kotlin"],"acf":[],"blog_post_summary":"<p>Hello developers! Welcome to 2022 \u2013 a great year to be developing for two screens! To kick off the new year we\u2019re going to do a quick recap of all the two screen enhanced components \u2013 across developer platforms \u2013 that can help you get started quickly with dual-screen and foldable support, while also providing [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/posts\/2113","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/users\/570"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/comments?post=2113"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/posts\/2113\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/media\/2121"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/media?parent=2113"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/categories?post=2113"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/surface-duo\/wp-json\/wp\/v2\/tags?post=2113"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}