titlebar

How to draw custom button in Window Titlebar with Windows Forms?

拥有回忆 提交于 2019-11-26 12:44:09
问题 How do you draw a custom button next to the minimize, maximize and close buttons within the Titlebar of the Form? I know you need to use Win32 API calls and override the WndProc procedure, but I haven\'t been able to figure out a solution that works right. Does anyone know how to do this? More specifically, does anyone know a way to do this that works in Vista? 回答1: The following will work in XP, I have no Vista machine handy to test it, but I think your issues are steming from an incorrect

Remove icon/logo from action bar on android

家住魔仙堡 提交于 2019-11-26 12:05:12
I've been trying to find some way of removing the icon/logo from the action bar but the only thing I've found after an hour of searching SO, Android's documentation and Google is how to remove the title bar in whole. That is not what I want. Only want to remove the icon/logo from the title bar. Any one know how to accomplish this? Preferably I'd like to do this in XML . If you've defined android:logo="..." in the <application> tag of your AndroidManifest.xml , then you need to use this stuff to hide the icon: pre-v11 theme <item name="logo">@android:color/transparent</item> v11 and up theme

Custom title with image

孤街浪徒 提交于 2019-11-26 09:20:46
问题 i\'m creating custom title for activity by disabling standard one and managing everything myself. I wonder if it\'s possible to replace/theme standart title to my needs. I can customize size, background image, and text via themes by changing windowXYZStyle items. The only thing i couldn\'t find - how i can add image instead of text. I\'ve tried requestWindowFeature(Window.FEATURE_CUSTOM_TITLE) and assign custom layout - but it doesn\'t seems to work. EDIT : Here is a report of testing

How to customize title bar and window of desktop application

百般思念 提交于 2019-11-26 08:10:00
问题 How could I customize the Title Bar (including: close, maximize, minimize buttons, title) and the Frame of desktop application written in PyQt so that it looks like the below image?. I need a way to specify the colors I want to use for title bar elements (buttons, text title and background-color of bar and buttons). the code which I need to change its window: import sys from PyQt5 import QtCore, uic from PyQt5.QtWidgets import QApplication, QDialog class MainWindow(QDialog): def __init__(self

how can i change the color of titlebar in JFrame?

扶醉桌前 提交于 2019-11-26 05:38:42
问题 I am using the following code, UIManager.put(\"JFrame.activeTitleBackground\", Color.red); for change the toolbar color in JFrame. But it didn\'t work. Is it possible to change the color of titlebar in JFrame? 回答1: Its not possible. The top level JFrame is controlled by the look & feel of the underlying OS. You CAN change the color of an InternalFrame . 回答2: //source : javax/swing/plaf/metal/MetalTitlePane.java import javax.swing.*; import javax.swing.plaf.*; import javax.swing.plaf.metal.*;

Changing WPF title bar background color

夙愿已清 提交于 2019-11-26 05:35:03
问题 I have a WPF Windows application. I need to change the background color of the title bar. How can I do that? 回答1: In WPF the titlebar is part of the non-client area, which can't be modified through the WPF window class. You need to manipulate the Win32 handles (if I remember correctly). This article could be helpful for you: Custom Window Chrome in WPF. 回答2: Here's an example on how to achieve this: <Grid DockPanel.Dock="Right" HorizontalAlignment="Right"> <StackPanel Orientation="Horizontal"

How to set different label for launcher rather than activity title?

六月ゝ 毕业季﹏ 提交于 2019-11-26 02:41:55
This question has been asked before - but with no satisfying answer at all! So I'm trying it again. I want to give my application launcher icon (the one that is displayed on the startscreen!) a different, shorter caption. It seems the launcher takes its label from the mainfest section about the main activity's label, as here: <activity android:name="MainActivity" android:label="@string/app_short_name"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> I already changed the original reference to my

How to set different label for launcher rather than activity title?

倖福魔咒の 提交于 2019-11-26 01:51:01
问题 This question has been asked before - but with no satisfying answer at all! So I\'m trying it again. I want to give my application launcher icon (the one that is displayed on the startscreen!) a different, shorter caption. It seems the launcher takes its label from the mainfest section about the main activity\'s label, as here: <activity android:name=\"MainActivity\" android:label=\"@string/app_short_name\"> <intent-filter> <action android:name=\"android.intent.action.MAIN\" /> <category

Set title background color

南笙酒味 提交于 2019-11-26 00:57:05
问题 In my android application I want the standard/basic title bar to change color. To change the text color you have setTitleColor(int color) , is there a way to change the background color of the bar? 回答1: This thread will get you started with building your own title bar in a xml file and using it in your activities Edit Here is a brief summary of the content of the link above - This is just to set the color of the text and the background of the title bar - no resizing, no buttons, just the

How to hide the title bar for an Activity in XML with existing custom theme

微笑、不失礼 提交于 2019-11-25 23:58:44
问题 I want to hide the titlebar for some of my activities. The problem is that I applied a style to all my activities, therefore I can\'t simply set the theme to @android:style/Theme.NoTitleBar . Using the NoTitleBar theme as a parent for my style would remove the title bar from all of my activities. Can I set a no title style item somewhere? 回答1: Do this in your onCreate() method. //Remove title bar this.requestWindowFeature(Window.FEATURE_NO_TITLE); //Remove notification bar this.getWindow()