toolbar

Text on an ActionBar Icon is not updating on new count

£可爱£侵袭症+ 提交于 2020-01-05 03:48:09
问题 am inflating menu item inside fragments onCreateOptionsMenu() . Point 1 : But here onCreateOptionsMenu is calling multiple time, am no where calling invalidateOptionMenu() inside fragment and am not getting why it is like this. Point 2: I am updating cart count (badge count) please look my code below, mCartCountTextView is member that hold the TextView,that holds count value. Am setting mCartCountTextView in some where of fragment by calling refreshCartCount() ,but the value of

Can't change the color of toolbar

烂漫一生 提交于 2020-01-04 04:06:08
问题 Can anyone please, explain me, why my toolbar doesn't change its color even though I created another style like: <style name="AppTheme.NoActionBar"> <item name="windowActionBar">false</item> <item name="windowNoTitle">false</item> </style> added it in my manifest file like: <activity android:name=".SettingsActivity" android:label="@string/title_activity_settings" android:parentActivityName=".MainActivity"> <meta-data android:theme="@style/AppTheme.NoActionBar" android:name="android.support

How to add a Text-only button in a toolbar in MFC

China☆狼群 提交于 2020-01-03 04:00:08
问题 I need to show a text-only button in a toolbar in MFC. How can I do it? I'm using Visual Studio 2005, so I'm not using MFC Feature Pack classes. Thanks 回答1: Try passing -1 as the image index and setting the button's text flag: toolBar.SetButtonInfo(buttonIndex, buttonId, TBBS_BUTTON | TBBS_AUTOSIZE | BTNS_SHOWTEXT, -1); toolBar.SetButtonText(buttonIndex, "Button Text"); 来源: https://stackoverflow.com/questions/3941193/how-to-add-a-text-only-button-in-a-toolbar-in-mfc

Change background color of title in CollapsingToolbarLayout using scrim or color overlay

孤街浪徒 提交于 2020-01-03 02:00:29
问题 I have been dealing for a while now with changing the color of the background of the title in the collapsingtoolbarlayout but only when is expanded. Why I want is either have a transparent scrim background or a color overlay (like the documentation says): I want this behaviour (or a protective screen with transparent background is also possible), the thing is I found exactly the same question on this post: Android CollapsingToolbarLayout Title background I've applied this solution to my

Visual Studio 2012 Toolbars

≡放荡痞女 提交于 2020-01-02 08:28:11
问题 Does anyone know of a way to move the toolbars alongside the menu bar in VS2012? My setup currently looks like this: I like to maximise code space, but find the toolbars useful - so rather than hiding them I'd prefer to lift them up alongside the menubar, and/or do away with the title bar. Is this possible? 回答1: Here is one option, not exactly what you are asking for but it does accomplish the goal of saving real estate. It is a Visual Studio Extension allows you to hide the main menus when

Using AppCompat Toolbar with FrameLayout

房东的猫 提交于 2020-01-02 07:32:10
问题 So my XML goes like this: <?xml version="1.0" encoding="utf-8"?> <android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/drawer_layout" android:layout_width="match_parent" android:layout_height="match_parent" > <android.support.v7.widget.Toolbar android:id="@+id/my_toolbar" android:layout_height="56dp" android:layout_width="match_parent" android:minHeight="?attr/actionBarSize" android:background="?attr/colorPrimary" /> <FrameLayout

Toolbar don´t work with pre-lollipops devices using appcompat v7

我怕爱的太早我们不能终老 提交于 2020-01-02 04:52:07
问题 I'm doing a simple code for a toolbar and menu drawer, using material appcompatv7. Everything works perfectly on the Nexus 5 with lollipop , but in a pre-lollipop (4.1 or 4.4) device crashes. The problem comes in defining the style. I put my code if anyone can tell me where the fault is. This is my main activity: import android.support.v4.widget.DrawerLayout; import android.support.v7.app.ActionBarActivity; import android.support.v7.app.ActionBarDrawerToggle; import android.support.v7.widget

How to change toolbar color

只愿长相守 提交于 2020-01-02 01:07:18
问题 I've been searching how to customize the toolbar, for example how to add background color, but I don't understand how it works. I've been trying to add a custom style for my toolbar but any result ... The Manifest <application android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:theme="@style/Theme.Design"> The style.xml file <resources> <style name="Theme.Design" parent="Base.Theme.Design"> </style> <style name="Base.Theme.Design" parent=

Reset VS 2008 toolbars

不羁岁月 提交于 2020-01-01 09:55:14
问题 How do I completely reset my Visual Studio 2008 toolbar? Right now I have toolbars randomly appearing/disappering when I write code vs. debug. Is this expected behavior? I'd like to get it to a point where the same set of toolbars appears and sticks to their same position in the toolbar area. 回答1: You can also run one of the following commands (if you can't get it to work in the command line in VS, run the regular command prompt in Windows. As Admin, if you're running Vista...): "Mild"

Specifying a custom configuration file for CKEditor

元气小坏坏 提交于 2020-01-01 05:30:39
问题 I am trying to add the CKEditor to a page I am currently developing but am having problems getting it to pick up my custom configuration file? I am using CKEditor in Visual Studio.NET 2008. I need to customize the toolbars that are displayed, as Basic is too minimal and Full would give an overwhelming amount of buttons to the user. I am declaring the editor in the aspx page as follows: <script type="text/javascript"> CKEDITOR.replace(document.getElementById("<%= txtTourItinerary.ClientID %>")