Android Dashboard Pattern

前端 未结 7 835
粉色の甜心
粉色の甜心 2020-11-28 18:47

In Tim Bray\'s latest Android blog post he mentions the \"dashboard\" ui pattern (what is used for the Twitter app, Facebook app, etc. Is this layout as simple as a GridVie

7条回答
  •  不知归路
    2020-11-28 19:15

    The Dashboard layout did not work for me, thus I suggest a layout based solution. It's just a bunch of layouts within layouts.

    The key is the relativity of weights between the spacing layouts and the content layouts.

    You can very simply move icons and define other layouts for bigger or lighter dashboards.

    Here is how it looks like:

    portrait

    And here is the xml:

    
    
        
    
        
    
            
            
    
            
    
                
    
                
            
    
            
    
            
    
                
    
                
            
    
            
        
    
        
    
        
    
            
    
            
    
                
    
                
            
    
            
    
            
    
                
    
                
            
    
            
        
    
        
    
        
    
            
    
            
    
                
    
                
            
    
            
    
            
    
                
    
                
            
    
            
        
    
        
    
    
    

    Here are the styles:

    
    
    
    
    
    
    
    
    
    
    
    
    
    

    Hope this helps someone. Enjoy.

提交回复
热议问题