使用Action Bar Android开发 [英] using Action Bar Android development

查看:64
本文介绍了使用Action Bar Android开发的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是android开发的新手. 我正在做一个小项目,应用程序的标题应该在中间,操作栏的左侧是textview.

I am new to android development. I am working on a small project, The title of the app is supposed to be in the center and a textview on the left side of the action bar.

我想知道这种方法是否正确. 1.我使用

I would like to know if the approach is correct. 1. I have hidden the actionbar using

 ActionBar actionBar = getSupportActionBar();
 actionBar.hide(); 

2.我开发了一种布局来替换这样的操作栏

2.I Developed a layout to replace the actionbar like this

这是正确的做法吗? 如果没有,正确的方法是什么?

So is this the correct was of doing it ? If not, what's the correct way ?

推荐答案

您的方法是正确的,但是请仔细阅读Slidenerd Material设计教程.您可以根据自己的规范创建自己的工具栏.以下站点可帮助您: 滑动式工具栏教程

Your way is correct but please go through the Slidenerd Material design tutorial. You can create your own toolbar with your specification.Following site help you: Slidenerd toolbar tutorial

这篇关于使用Action Bar Android开发的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆