Sherlockアクションバーの中央にカスタムテキストを追加することは可能ですか?
ボタンを追加するときのように右側に設定したり、ロゴの横に設定したりできることは知っていますが、バーの中央にはどうでしょうか。
編集:
これを実行するとレンダリングされますが、バーの中央に配置されていません。
LayoutInflater linflater = (LayoutInflater) getSystemService(getApplicationContext().LAYOUT_INFLATER_SERVICE);
View GalleryTitleView = linflater.inflate(R.layout.gallery_title_layout, null);
GalleryTitleTv = (TextView) GalleryTitleView.findViewById(R.id.GalleryTitleTv);
ActionBar.LayoutParams lp = new ActionBar.LayoutParams(ActionBar.LayoutParams.WRAP_CONTENT, ActionBar.LayoutParams.WRAP_CONTENT);
lp.gravity = Gravity.CENTER_HORIZONTAL;
GalleryTitleView.setLayoutParams(lp);
getSupportActionBar().setCustomView(GalleryTitleView);
getSupportActionBar().setDisplayShowCustomEnabled(true);