简体   繁体   中英

How can I set Styles and Themes to linearlayout, programmatically in android?

如何在Android中以编程方式将Styles和Themes设置为linearlayout?

You can implement it by using a dynamic structure where all the designing info will come from server

  1. For that you have to create a xml having list of themes what names you required to give associated with an id.
  2. Parse xml and show its content to a list then at selection of an item of list save id associated with it in your shared preferences.
  3. Each time when the designing part will be loaded you will send id with it as http://xyz.abc.com/images/menu-images/your_id which will respond you with an image or design info related to that theme id.
  4. To save downloading each time of content indroduce a check that if value saved in preferences then use existing image saved or cached in application.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM