{"id":1228,"date":"2019-04-30T12:37:39","date_gmt":"2019-04-30T07:07:39","guid":{"rendered":"http:\/\/blog.openwebsolutions.in\/?p=1228"},"modified":"2019-04-30T12:37:39","modified_gmt":"2019-04-30T07:07:39","slug":"accordions-mobile-applications","status":"publish","type":"post","link":"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/","title":{"rendered":"All About Accordions On Mobile Applications"},"content":{"rendered":"<p>An accordion is a design controlled element displayed as a stack of items that expands to expose some hidden information. Accordions push the page content down besides being placed on top of page content. Accordions seem to be a fabulous idea for shortening long content pages. However, in most of the situations when all the page content is relevant to users, it is more feasible to show all the content at once, even if doing so results in longer pages. The research studies show that people scroll when information is beneficial and properly formed for scanning.<\/p>\n<p>XML layout For Accordion:<\/p>\n<p>&lt;com.brandonhogan.accordionview.AccordionView<br \/>\nandroid:id=&#8221;@+id\/accordion_one&#8221;<br \/>\nandroid:layout_width=&#8221;match_parent&#8221;<br \/>\nandroid:layout_height=&#8221;wrap_content&#8221;<br \/>\napp:titleColorHighlight=&#8221;@color\/colorAccent&#8221;\/&gt;<\/p>\n<p>&nbsp;<\/p>\n<p>java\u00a0 activity For Accordion:<br \/>\nimport android.support.v7.app.AppCompatActivity;<br \/>\nimport android.os.Bundle;<br \/>\nimport android.view.LayoutInflater;<br \/>\nimport android.view.View;<br \/>\nimport android.widget.TextView;<\/p>\n<p>import com.brandonhogan.accordionview.AccordionView;<\/p>\n<p>public class MainActivity extends AppCompatActivity {<\/p>\n<p>private AccordionView accordionViewOne;<br \/>\nprivate AccordionView accordionViewTwo;<\/p>\n<p>@Override<br \/>\nprotected void onCreate(Bundle savedInstanceState) {<br \/>\nsuper.onCreate(savedInstanceState);<br \/>\nsetContentView(R.layout.activity_main);<\/p>\n<p>accordionViewOne = (AccordionView) findViewById(R.id.accordionOne);<br \/>\naccordionViewTwo = (AccordionView) findViewById(R.id.accordionTwo);<\/p>\n<p>setupAccordionOne();<br \/>\nsetupAccordionTwo();<br \/>\n}<\/p>\n<p>private void setupAccordionOne() {<br \/>\nLayoutInflater inflater = LayoutInflater.from(getApplicationContext());<\/p>\n<p>accordionViewOne.setTitle(getResources().getString(R.string.accordion_one_title));<\/p>\n<p>View areaView = inflater.inflate(R.layout.accordion_content_one, accordionViewOne, false);<\/p>\n<p>TextView builderName = (TextView) areaView.findViewById(R.id.textviewone);<br \/>\nbuilderName.setText(getResources().getString(R.string.accordiononeContent));<\/p>\n<p>accordionViewOne.addContentView(areaView);<br \/>\n}<\/p>\n<p>private void setupAccordionTwo() {<br \/>\naccordionViewTwo.setTitle(getResources().getString(R.string.accordiontwoTitle));<\/p>\n<p>TextView contentTwo = new TextView(getApplicationContext());<br \/>\ncontentTwo.setText(getResources().getString(R.string.accordiontwoContent));<\/p>\n<p>accordionViewTwo.addContentView(contentTwo);<br \/>\n}<br \/>\n}<\/p>\n<h3>Accordions Is immense On Mobiles:<\/h3>\n<ol>\n<li>It tells users about the contains of the pages and whether the type of facts is likely to be applicable for their search.<\/li>\n<li>It gives users a direct approach to a section of importance.<\/li>\n<li>It helps users form a crucial model of the page and, likely, of the site.<\/li>\n<\/ol>\n<h3>Criteria for Applying Accordions:<\/h3>\n<p>The finest place to begin when conclusive to use an accordion is to figure out common and analytical use cases for users.<\/p>\n<p>Accordions are good enough when people need only some key pieces of content on a single page. Hiding most of the content, users can contribute their time more accurately concentrating on the few topics that matter.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>An accordion is a design controlled element displayed as a stack of items that expands to expose some hidden information. Accordions push the page content down besides being placed on top of page content. Accordions seem to be a fabulous idea for shortening long content pages. However, in most of the situations when all the [&hellip;]<\/p>\n","protected":false},"author":43,"featured_media":1684,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[113,78],"tags":[90,79,127],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v14.8.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>All About Accordions On Mobile Applications - Openweb Solutions Blog<\/title>\n<meta name=\"robots\" content=\"index, follow\" \/>\n<meta name=\"googlebot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta name=\"bingbot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"All About Accordions On Mobile Applications - Openweb Solutions Blog\" \/>\n<meta property=\"og:description\" content=\"An accordion is a design controlled element displayed as a stack of items that expands to expose some hidden information. Accordions push the page content down besides being placed on top of page content. Accordions seem to be a fabulous idea for shortening long content pages. However, in most of the situations when all the [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/\" \/>\n<meta property=\"og:site_name\" content=\"Openweb Solutions Blog\" \/>\n<meta property=\"article:published_time\" content=\"2019-04-30T07:07:39+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2019\/04\/accordion.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"800\" \/>\n\t<meta property=\"og:image:height\" content=\"600\" \/>\n<meta name=\"twitter:card\" content=\"summary\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#website\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/\",\"name\":\"Openweb Solutions Blog\",\"description\":\"Transforming ideas into reality\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/openwebsolutions.in\/blog\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2019\/04\/accordion.jpg\",\"width\":800,\"height\":600},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/#webpage\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/\",\"name\":\"All About Accordions On Mobile Applications - Openweb Solutions Blog\",\"isPartOf\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/#primaryimage\"},\"datePublished\":\"2019-04-30T07:07:39+00:00\",\"dateModified\":\"2019-04-30T07:07:39+00:00\",\"author\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#\/schema\/person\/049b636dd33373206802590bcf362e91\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/openwebsolutions.in\/blog\/accordions-mobile-applications\/\"]}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#\/schema\/person\/049b636dd33373206802590bcf362e91\",\"name\":\"Mousumi Majumdar\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/6f7d1ff641ab660b19e3733994d37207?s=96&r=g\",\"caption\":\"Mousumi Majumdar\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","_links":{"self":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/1228"}],"collection":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/users\/43"}],"replies":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/comments?post=1228"}],"version-history":[{"count":7,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/1228\/revisions"}],"predecessor-version":[{"id":1680,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/1228\/revisions\/1680"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/media\/1684"}],"wp:attachment":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/media?parent=1228"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/categories?post=1228"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/tags?post=1228"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}