FAQ Database Discussion Community


How to make glassy button with drawable on top?

android,button,styling
I want to make a glassy button with application icon drawable on top. I tried with Button view, I have set the background to some ugly drawable I made, and attached the icon by drawableTop The issue is that the icon isn't centered, so I tried to use ImageButton but...

Google Map not displaying after applying custom style

google-maps,styling
I have nearly finished the code below which displays markers from an array, each with their own infoBox. The final step is to style the map but despite following many online tutorials to the letter (changing the relevant bits to match my code) all I am getting is a totally...

What kind of font is used in this logo_

css,fonts,styling
I am not sure if this question is fit for SO but if anybody could help me that would be fine. http://www.mdvstyle.com/wp-content/themes/mdv-child/img/logo.png It doesn't have to be the exact same font, but something similar....

How to margin div inside other div?

html,css,styling
html body,simple form with table and two divs inside(login and table): <body> <div id="container"> <form> <div class="login"> <div class="table"> <table class="userInput"> <tr> <td><input type="text" placeholder="Username" id="username" name="login"></td> </tr> <tr> <td><input type="submit" value="submit"></td> </tr> </table> </div> </div> </form> </div> </body> My css: html,body { margin: 0; padding: 0; height:...

Data Points for Path to draw a tick mark

wpf,xaml,styling
Can anyone specify the data points to be used to get a tick mark like the following I use this <Path Name="TickMark" Fill="Black" Data="M0,4 5,9 9,0 4,5" Visibility="Hidden" /> But doesnt look like the above,It looks like ...

Replace ControlTemplate with minimum code reproduction

wpf,combobox,styling,controltemplate
I wanted to modify the standard WPF ComboBox to also show an image on the left when IsEditable is set to true. This is what I ended up with: A ResourceDictionary in a separate XAML file with these contents: <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:theme="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"> <LinearGradientBrush x:Key="ButtonNormalBackground" StartPoint="0,0"...

Why is my z-index not working in this code?

html,css,z-index,styling
I have a website here with a sidebar, but I want the sidebar to be hidden until the user clicks on a menu button. Anyways, my .sidebar is on z-index: 0; while my .page-content is on z-index: 1;. Why is the sidebar not hidden when I load the webpage? I...

CSS highlight links with custom border

html,css,styling
I need a little help with my problem. I get following effect with this code: #navLink{ font-family: oduda_bold; font-size: 17px; color: #fff; text-decoration: none; } #navLink:focus{ border-radius: 10px; border-style: solid; border-width: 0px; background-color: #ef5e99; } WRONG HIGHLIGHT and I would like to have it highlighted like this: NICE HIGHLIGHT Is...

How to style Android's AppBar action text?

android,styling,appbar
I need to change text size of action buttons in AppBar/Toolbar. It should be 14sp, but I'll use 20sp in this example, because it is more evident. I am using appcompat-v7 22.1.1 At first I tried to use theme attribute android:actionButtonStyle: <style name="FirstAttemptTheme" parent="Theme.AppCompat.Light.DarkActionBar"> <item name="android:actionButtonStyle">@style/Custom.Widget.AppCompat.Light.ActionButton</item> </style> <style name="Custom.Widget.AppCompat.Light.ActionButton"...

Error using nth-child

html,css,styling
I have this: a { display:table; } a:hover { text-decoration:none; } a:first-child { color:#00FF00; /* green */ } a:nth-child(3) { color:#FF0000; /* red */ } <a href="www.google.com">Google<a> <a href="www.google.com">Google<a> <a href="www.google.com">Google<a> Question: Why is the second "Google" red and not the third? Whats happening here?...

Setting AlternatingRowBackground for DataGrid with Templated DataGridRow

wpf,datagrid,styling
I need to have DataGrid with black and dark gray rows. By default it would have gray rectangle in the left of each row (marked by red in screenshot) which I don't need. To remove it I have to use Template for DataGridRow. The problem I get is that AlternatingRowBackground...

Change Z-Index of a label control in code [duplicate]

c#,controls,z-index,styling
This question already has an answer here: Bring Winforms control to front 4 answers So I'm trying to create a label with the following code : Label letter = new Label(); String key = Convert.ToString(e.KeyChar); letter.Text = key; letter.ForeColor = textColor; letter.Size = new Size(10, 20); letterSpacing = letterSpacing...

How to set font attributes for all text in a chart?

json,coldfusion,styling,zingchart
I have a ZingChart (through cfchart) that has an external JSON styling file. How can I set font attributes, such as font-family, font-weight, font-size for all text in the chart, without setting it individually? My JSON file so far: { "graphset":[ { "background-color":"white", "font-family":"Courier New", "scale-x":{ "label":{ "text":"Date" } },...

How do I apply styling to sorted columns in Angular ui-grid?

angularjs,sorting,styling,angular-ui-grid
I have a ui-grid with some narrow columns and when I apply a sort to these columns, the little arrow that indicates the sort and its direction doesn't show. So I'd like to be able to style the column cells, or just the column header, according to the column sort...

How to style a tag for current div with css?

html,css,tags,styling
My div: <div id="dialog" class="window"> <table class="modalWindow" border="1"> <tr> <td colspan="2"><input type="text" id="feedName" value="" /></td> </tr> <tr> <td><input type="submit" id="renameFeed" value="Submit"></td> <td><a href="#" class="close">Close it</a></td> </tr> </table> </div> Need to style <a href="#" class="close">Close it</a> with css for current div. How to do it?...

Wordpress: track down and remove pseudo element from wp_head [closed]

php,css,wordpress,header,styling
I have a site visible here where I have created a child theme in order to add a custom header and footer from the rest of the (non blog) website. I've removed everthing from the existing header apart from <?php wp_head(); ?> as this is required to call many other...

How to center two square blocks in page?

html,css,styling
I have a page where I'm displaying the status of two websites -- as in if they're currently up and running, or not. If the site is up, I want the block to have a light green background, and if not, a light red one. And the site's name should...

How can I control my

styling in another styling?

javascript,html,css,styling
Hey guys I'm looking to control my <h1> styling from another set of styling rules. I know how to do this with JavaScript but I'm wondering if I could do this CSS only. To get a better example of what I mean check out the example below: h1 { color:...

Input button image disappears on submit

html,css,styling
I have a form: <form action="/search" class="search-form" method="get"> <fieldset> <input id="q" name="q" type="text" value="Enter search text here"> <input type="submit" value="search" class="search-button"> </fieldset> </form> With some CSS to style the button: .search-button { background:url("images/search.gif") no-repeat 0 center; text-indent: -9000px; border:none; display:inline-block; width: 23px; background-position-y: 4px; background-position-x: 5px; } .search-button:hover {...

Is it possible to wrap looping PHP output in tags?

php,loops,styling
everyone. I'm having a bit of a PHP conundrum here and I couldn't find a good answer that already existed. You see, I'm working on a project where I have to take a classmate's discography website and revamp it with PHP, to where, instead of having the album covers and...

Enumerate and apply WPF styles programmatically

c#,wpf,xaml,storyboard,styling
I have a WPF button as such <Button Name="HelloWorldButton" Width="100" Height="100" HorizontalAlignment="Center" VerticalAlignment="Center" Style="{StaticResource TileButton}"> Hello world </Button> Using WPF styling I have applied a style template as shown below <Style x:Key="TileButton" TargetType="Button"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="Button"> <Border x:Name="focusRect" Margin="-6" BorderThickness="6"> <ContentPresenter />...

How do I get the Onmouseover method to apply universally to all links?

class,styling,highlighting,onmouseover
We're aware of that amazing trick which allows users to highlight a link. But, you must repeat it for each link. for example: a href="https://www.yahoo.com" Onclick="window.open(this.href); return false" onmouseout="this.style.color = '#0000ff';" onmouseover="this.style.color = '#e3FF85';" align="justify">Yahoo. But, I would like this code to apply to every link on the page. I've...

Is there any way to increment a CSS value depending on nth-child variable?

html,css,styling
This is probably a long shot but, here it goes: I have this: <style> .select-option.hidden:nth-child(2) { top: 65px; } .select-option.hidden:nth-child(3) { top: 100px; } .select-option.hidden:nth-child(4) { top: 135px; } .select-option.hidden:nth-child(5) { top: 170px; } .select-option.hidden:nth-child(6) { top: 205px; } </style> I want something like this: .select-option.hidden:nth-child(n+2) { top: (30+((n-1)*35))px; }...

Detect if a key should be treated as a style or attribute

javascript,css,dom,styling
I have the following function : var applyStyling = function (element, object) { return _.each(object, function (value, key) { // determine whether the key should be treated as an attribute or style if(style) element.style.key = value element.setAttribute(key, value) }) } An example use would be something like applyStyling('some dom element',...

Getting background color to fill the entire element

html,css,design,styling
I don't quite understand why this code acts like this. If I do this... HTML: <body> <header> <h1> MY HEADER </h1> </header> <article> <p>Lorem ipsum dolor sit amet...</p> </article> <footer> <p>This is my footer</p> </footer> </body> CSS: body { width: 60%; margin: 0 auto; } article { background: #AAA; }...

WPF ListView.ItemContainerStyle Presses All ListViewItem Elements Together

c#,wpf,listview,styling
This is what my original ListView looked like: Note that the ListView is inside a Grid column (if you want the view's full XAML, I'll edit the post later). Here is the ListView's XAML: <ListView Name="Worklist" Margin="5 2 5 5" BorderBrush="Transparent" Width="275" HorizontalAlignment="Left" Background="{StaticResource AppBackground}" SelectedIndex="{Binding WorklistIndex}"> <ListView.ItemTemplate> <DataTemplate> <Border...

HTML TextBox permanent text behind number

html,css,textbox,styling
I wanted to create a textbox for a unit measurement. E.g "1 Kg". I know can wrap a text just behind the textbox, but I wanted the unit to be inside the textbox itself. While the number can be changed, the unit behind it should stay just at the end...

Width of the expander header affects the scrollviewer outside

c#,wpf,styling
The below is my code <Window x:Class="ScrollTester.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="MainWindow" Height="350" Width="525"> <Window.Resources> Here I have set the datatemplate for the header of the expander I am using inside the stack Panel <DataTemplate x:Key="titleText"> <Border Background="Green" Height="24"> <TextBlock Text="{Binding}" Width="{Binding RelativeSource={RelativeSource Mode=FindAncestor,...

CSS Styling (Text, and paragraph backgrounds) [Solved]

html,css,styling
I wish to create a site that displays paragraphs of my information with say a white background, and I want the paragraph background to be black, but with a low opacity as to clearly distinguish it from the rest with a different color and 100% opacity for the text I'm...

How to explore styling in android

android,styling
I'm trying to theme my app in Android. However, each widget is an excrutiating pain in itself: I have to search for theming that particular widget and then create a style that hopefully derives from same style that widget uses. Of course, answers about theming a particular widget don't always...

Need help styling on javascript

javascript,styling
var stateData = { MA: { fullName: 'Massachusetts: some infor here | some info here | test'}, VA: { fullName: 'Virginia:' }, VA: { fullName: 'Virginia' }, VA: { fullName: 'Virginia' }, VA: { fullName: 'Virginia' }, VA: { fullName: 'Virginia' }, VA: { fullName: 'Virginia' }, VA: { fullName:...

How can I get the current state of my div animation?

html,css,safari,styling
I am using Safari, thus to make it easier to answer my question I will just use the -webkit- prefix on my animations. I am making a menu that is in the corner. When the user hovers, it spans the entire website until the user leaves the menu, then it...

How do you style an android app?

android,css,styling,look-and-feel
I've been doing web development for some time, and now I want do learn android. I know java and that is fine. What interests me is how do I style my app. For example if I would like to put some border on my button, or add a shadow. If...

Styling woocommerce description

html,css,wordpress,woocommerce,styling
I'm creating this site http://pmgoalkeeperacademy.com/wordpress/ and am running into a big problem! There is 2 descriptions in the "Product" page, 1 above the tabs and 1 inside the tabs. I need to get the text color in the "tab" section to black. I have found out that if I change...

Android Spinner, selector icon location

android,spinner,styling
I wonder if (and how) it's possible to change the icon location of the Spinner's selector icon. At this point I've got my spinner's width matching the parent (full screen) and then got the text centered. So at this moment, the text is centered but the selector icon is at...

LESS formatting

css3,less,styling
I have been writing some LESS CSS code recently, and was wondering what the best way for format this would be. Ideally i don't want to reproduce the button classes, and separate them from the input tags, unless that's the best way to go. .button, button, input[type="submit"], input[type="reset"], input[type="button"] {...