Delphi TTabControl - easy way to change colour of Horizontal Line - android

Is there an easy way to change the colour of the horizontal line that appears
when the TAB is active?
Usually it appears as Green... I use Edit Default Style to change the colour to blue/red when Text is active, but I could not find an equivalent for the Green Horizontal line?
(if can't see above Image, see
Is the Green an android / windows / Delphi default? I see some images with green shapes inside the Edit Default Style properties...
Can the Green horizontal line be changed to blue/red easily?
Can the Green horizontal line be disabled (set Invisible) easily without disabling the Active/non-active feature of the Tab text? I suppose I can set the Tab text to non-styled, and then manually change the colour of the Tab Text... but will be less elegant
Thanks for any input. I've checked the web for any link I can find (including How to change the color of active TAB in a TabControl, in Delphi)

The style used to paint the bottom line in the tabitems is TabItemStyle.Top.ActiveLink
You can use the style designer to change which rectangle is used for ActiveLink. For instance, you could click on this property to bring up the bitmaplinks editor, and then drag the rectangle so that the bottom line is not part of ActiveLink, and then your colored line is not drawn.

Related

android : what decided edit text default border colour on focus

I have two different apps and how the edittext appears in both are different. In one when i focus , the border is getting an orange colour and in other app its blue. I am not setting background in either the app. So how is the difference coming. Is it the android version selected ?
The default styling of widgets is controlled by the theme used by the activity. From your described symptoms, my guess is that you have not specified any theme, which means that you will get an orange focus ring on Android 1.x/2.x, a blue border on Android 3.x/4.x, and IIRC a gray border (subject to custom tints) in Android 5.0+.
More tactically, the focus is part of the EditText background, which will be a StateListDrawable pointing to other drawables for the various states (normal, focused, disabled, etc.).

How to create arrow type layout?

I have start and end date time fields that look like in picture below. Blue color shows active selection - if we select right then blue color goes to right and white color appears on the left and vice versa.
Hardest part is to create that arrow style in the middle. What should i use because buttons are rectangles and I don't know how it could be done.
It's easy. Just use ninepatch.
You can start there:
http://radleymarx.com/blog/simple-guide-to-9-patch/
you need a custom image according to what you ask, maybe extend ToggleButton for that but basically what you want is the same component when pressing on two different places on the same component will dispatch different events.
I would for example extend Linear layout, make it vertical layout, put two clickable textView\buttons with 9 patch images as background ,like suggested before, one for the white part and the other for the blue part. and replace the background image for any event u like.
you can also create a StateListDrawable with actions for selected and deselected and set the state of each drawable upon the right click

Underline of Edittext control disappears in Xamarin

I am using the Holo Dark Theme in my Android application in Xamarin. I devided my page (Activity) in different layouts. And I gave one the left layouts a white background (in contrast to the default black background of the Holo Dark Theme).
The Edittext controls in the dark side have the default gray underline bellow the edittext control (right side).
But this underline has now disappeared in the white area. Look at the picture:
I don't know why. How can I make the line visible again?
The bottom border of EditText control is draw as a background on Android. Maybe you changed the background of EditText controls so that the gray bottom borders are disappeared.

Change Android blue color scheme

On Android ICS you get the standard blue highlight color for all user controls, you get this on elements like textviews, highlights on buttons, indications on the end of a scrollview and tabwidgets.
Is there a way to change all the color's at once using a theme?
Thanks in advance!
Cheers!

How do I set the color for a tabview in android?

I want to change the colour of a tabview from the default grey (and black when not selected) to red and green when not selected.
In the tab Widget class I'm trying to set the colour using these functions
tabHost.setBackgroundColor(Color.RED);
tabHost.getTabWidget().setBackgroundColor(Color.GREEN);
But they don't work, its still the default colour. How do I manually set the background and tab colours of a tab widget in android? Also, is it possible to do it in xml?
See Step 4. at this blog, it's how I have done it, very simple, easy to change and tweak if you need to and it's all in XML.
Custom tabs in android tabhost

Categories

Resources