FAQ Database Discussion Community


How to remove button border style?

button,styles,autohotkey
In autohotkey, how do you remove the black button border? I just want a button without any border on it. I've tried all these style modifiers to no avail. gui, add, button, hwndMyButton Control, Style, -0x0,, ahk_id %MyButton% ;remove BS_PUSHBUTTON Control, Style, -0x1,, ahk_id %MyButton% ;remove BS_DEFPUSHBUTTON Control, Style, +0x8000,,ahk_id...

WPF - How to highlight a combobox border when focused

wpf,combobox,styles
I trying to create an application combo box theme. However I need the combo box border to change colour when tabbed to. I've tried everything, but I can't seem to get it right. Any help would be appreciated. <SolidColorBrush x:Key="NouvemWhiteBrush">White</SolidColorBrush> <SolidColorBrush x:Key="NouvemSecondaryMainBrush">#FFF58E0F</SolidColorBrush> <Style TargetType="{x:Type ComboBoxItem}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type...

Android app theme textViewStyle doesn't work on phone

android,xml,textview,styles,android-theme
I have so specific problem. I'm applying theme for all textviews. It appears on preview but when I run this app on phone I face with unstyled textview. The styles I set for other views are working. only textviewstyle is not working. In this sample textview color is green in...

Print a list with the original style

python,list,printing,styles
I'm using python and I've got a txt database with values like 24,50,55,5754 Now I want to print for example the last three digits in the same style: Output: 50,55,5754 I created a list: str.split(",") And then want to print: print (str[1:4]) However it then of course prints it like:...

Android custom button style not working

android,styles
I have this style on my styles.xml: <style name="btnStyleGenoa" parent="@android:style/Widget.Button"> <item name="android:textSize">15sp</item> <item name="android:textStyle">bold</item> <item name="android:textColor">#FFFFFF</item> <item name="android:gravity">center</item> <item name="android:shadowColor">#000000</item> <item name="android:shadowDx">1</item> <item name="android:shadowDy">1</item> <item...

TimePicker not displaying on android 4.4.2 - screenshots attached

android,dialog,styles,android-4.4-kitkat,timepicker
I have 2 phones, a Nexus 4 with Android 5.0.1, and an LG f60 with Android 4.4.2 on it. I have a custom dialog with this layout: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/linearLayout1" android:layout_width="fill_parent" android:layout_height="fill_parent" android:gravity="center" android:orientation="vertical" > <DatePicker android:id="@+id/datePicker1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:calendarViewShown="false" >...

WPF: apply style only to one tabcontrol containing other tabControl

wpf,xaml,styles,tabcontrol
In my wpf application, I have a tabControl (parent) that contains another tabcontrol (child). I would like to apply a style to the tabItem of the parent tabControl without affecting the child one. I tried with this: <TabControl x:Name="Parent" TabStripPlacement="Left" ItemsSource="{Binding Path=ParentTabItems, Mode=OneWay}" > <TabControl.Resources> <Style TargetType="{x:Type TabItem}"> <Setter Property="Template">...

Coding Style for User defined Exception in java

java,exception,design-patterns,styles
I'm working on a java project. while browsing the existing code of User defined Exception class, i came across a the code written like below: public final class ApplicationException extends RuntimeException { public static void enforce(final String message) { throw new ApplicationException(message); } private ApplicationException(final String message) { super(message); }...

Unexpected behavior of AlternativeRow BackColor in WPF

c#,wpf,datagrid,styles
I'm styling my DataGrid using an style provided by Microsoft at this page. I'm not changing this style except a single line as following that enables alternative row back color. <!--Style and template for the DataGrid.--> <Style TargetType="{x:Type DataGrid}"> <Setter Property="AlternationCount" Value="2"/> ... and the rest of the style I...

HTML email coding

html,email,styles
I am altering an html email template created by previous designer. It doesn't look right to me: <html style="margin: 0;padding: 0;border: 0;width: 100%;height: 100%;"> <head> </head> <style type="text/css"> I would have thought 'style' goes into 'head' and 'html style="..." looks confusing. I am not an expert on html emails, just...

li and a element styling issue with Chrome after clicking a link

html,css,google-chrome,styles,html-lists
I have a simple menu that works fine in Firefox, but when using Chrome the links move around when you click on them and so it breaks the styling. I read from somewhere that display: block; on a element would fix this, but it didn't. You can see a demo...

Indenting text on html select tag

css,css3,cross-browser,styles
I have a select tag which I am trying to give some style. <select class="points-selection" ng-options="line as line.pick for line in slip.lines"> </select> then I have this .points-selection { background-color: get-color(nieve); border: 0; border-radius: get-space(xxx-small); color: get-color(night); cursor: pointer; margin-top: get-space(xxx-small) + 1.5; padding: get-space(xxx-small); text-indent: 32.5%; width: 100%; }...

How to change colors of Gui-elements belonging to preferences?

android,styles,preferences
I have a PreferenceFragment, which displays several kinds of Preferences. Is it possible to change that blue color of the switch which belongs to a SwitchPreference and the radio buttons, line and title of the dialog which belongs to the ListPreference by assigning own colors to style-attributes ? My base...

CSS - Adding background images in the body of a website not working.

html,css,website,styles,background-image
Here I have some css styles that alter the layout of all webpages for my website, with a wrapper that is 900px wide a header and the main body. So far I've changed the background colour in the body section which works great. However if I add some code to...

How use layer-list to create custom background

android,xml,styles
I'm trying to play the background image below using layer-list, but without much success -> http://i.stack.imgur.com/5XBFL.png I used this example <?xml version="1.0" encoding="utf-8"?> <item android:top="1dp" android:left="1dp" android:bottom="5dp" android:right="5dp"> <shape android:shape="rectangle"> <size android:width="20dp" android:height="3dp"/> <solid android:color="#f00"/> </shape> </item> <item android:top="4dp" android:left="1dp" android:bottom="5dp" android:right="5dp">...

Edit Style Attribute of every div in a list

javascript,html,css,styles
I'm trying to write a script to help out a colourblind friend of mine. He's on a page laid out like this: <div class="message-pane-wrapper candy-has-subject"> <ul class="message-pane"> <li><div style="color:#700400"></div></li> <!-- many more li items --> </ul> </div> What I'm trying to do is use JavaScript to change all of the...

Q: I need idea to display a string with css, jquery or any other techniques (no php)

php,jquery,css,design,styles
I have a big problem. I have a mysql database which contains 12 character length fields. I would like to display somehow. Sample data from the field: 233215334523 I would like to display 0 and 1 with red background 2 3 with yellow background and 4 5 with green background....

incorrect status bar translucent displays on sony on lollipop

android,styles,statusbar,material-design,material
I have my styles.xml in values-v21. When I run my app on different Sony devices I see statusbar translucent like in android 4.4, but not 5.x. Anyone know the solution? code: <style name="BATheme" parent="Theme.AppCompat.Light.NoActionBar"> <item name="android:colorPrimary">@color/colorPrimary</item> <item name="android:windowTranslucentStatus">true</item> <item name="android:windowDrawsSystemBarBackgrounds">true</item> <item name="android:windowActionBar">false</item> <item...

How to position checkbox and text

jquery,html,css,checkbox,styles
I'm having some trouble positioning these checkboxes with its respective text. The actual checkboxes were hidden so that a personal style could be used. Anyway, this is purely a CSS issue. The text should be positioned in front of the checkboxes. I've been banging my head against the wall and...

HTML/CSS: Link Styling being used for image hyperlinks, and I can't get it to stop?

html,css,hyperlink,styles
I am adding links to images and I can not remove the a:link style and a:hover style that is designated for my text links. I added in a new .css style for a.button:link and a.button:hover, #content a.button:link { text-decoration:none; } #content a.button:hover { text-decoration:none; } and set the <a href="www.website.com"...

WPF custom button

wpf,button,styles
I start to learn WPF and there is something that is still unclear for me: i created new Style for button: <!-- no border button style --> <Style x:Key="NoBorderButton" TargetType="Button"> <Setter Property="Foreground" Value="White" /> <Setter Property="Background" Value="Transparent" /> <Setter Property="BorderBrush" Value="Transparent" /> <Setter Property="BorderThickness" Value="0" /> <Style.Triggers> <Trigger Property="Control.IsMouseOver" Value="true">...

How to add css class to style.css?

jquery,css,styles
I have this code by helping of skobaljic which add title to class in div $(document).on('ready', function() { $("[title*='animotion']").addClass(function(){ $(this).parent().css('overflow','visible'); return $(this).attr('title'); }).removeAttr('title'); }); <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script> <p><img src="http://placehold.it/350x150" title="animotion newClass new1" /></p> How to add these new classes to style.css with jQuery?...

Give Excel style through SAS

excel,styles,export,sas
I have the following issue. I want to conver a sas7bdat data set into an excel file with some formatting and style. The output of the sas data set is the following. And the Excel output should be the following. How can I make the style change through SAS? I...

How to set width and height in jQuery

javascript,jquery,styles,height,width
I have a background image and I am trying to optimize the site by specifying height and width for all images. I cannot figure out how to set width to 450 and height to 350. <!-- BACKGROUND IMAGE --> <script src="js/supersized.3.2.1.min.js"></script> <script type="text/javascript"> jQuery(function($){ $.supersized({slides:[{image:"/images/heritage/background.jpg"}]});}); </script> ...

Constructing book cover using div and CSS

html,css,styles
Is it possible to use some divs and css to make a book cover like the one below(ignore the orange background) with editable titles, most the book covers I checked online don't look like this. I know am probably asking a lot but I would really appreciate any help on...

Change icon on ActionBar tab click or swipe - Android

android,android-layout,android-actionbar,styles,android-tabs
It took me a long time just to get my ActionBar tab icons in the split ActionBar, as well as get the tab indicator color to white. So now all I need to do is to swap the icon with a different color, when it is unselected. The selected icon...

Any idea with font-size of 1.05em/1.2em?

css,styles,font-size
I saw a vid on Youtube and noticed that the font-size of body is 1.05em/1.2em. http://i.stack.imgur.com/KvWbY.png However, I tried this setting like 1.4em/1em vs. 1.4em. It seems to be a little bigger for 1.4em/1em, but there's no difference between 1.4em/1.4em or things like this. Any idea with this kind of...

How to delete overlay in an Android modified Holo button?

android,button,styles,overlay,android-theme
I have this style for Buttons in my Android app, but I don't want that little shadow. <style name="AppTheme.Button.Primary" parent="@android:style/Widget.Holo.Button"> <item name="android:background">@color/primary_dark</item> <item name="android:textColor">@color/primary_light</item> <item name="android:gravity">center</item> <item name="android:textSize">15sp</item> <item name="android:layout_width">20dp</item> <item...

WPF add new Slider style cause XamlParseException

wpf,slider,styles
i found this slider style that i want to add. i added all the 3 styles inside my Window.Resources and also put in the first style the 2 templates: <Style TargetType="{x:Type Slider}"> <Setter Property="FocusVisualStyle" Value="{StaticResource MyFocusVisualStyte}" /> <Setter Property="SnapsToDevicePixels" Value="true" /> <Setter Property="OverridesDefaultStyle" Value="true" /> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type...

Cycle through array with animation

jquery,html,css,animation,styles
So I want to cycle through a list of arrays when I click the button, I've found info but can't figure out how and where to put it into the code I have already, check the below to see what I have already; My Current Code [1]: http://codepen.io/anon/pen/PqKYwz If anyone...

Global style isn't being applied

c#,wpf,xaml,styles
I have a resource dictionary file as so: <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:TIMS.Common"> <local:ViewModelLocator x:Key="ModelLocator" /> <Style x:Key="DefaultWindowStyle" TargetType="Window"> <Setter Property="Background" Value="Cyan" /> </Style> <Style x:Key="DefaultPageStyle" TargetType="Page"> <Setter Property="Background" Value="Red" />...

jquery: how to determine if a style is set via css class or hardcoded by style attribute? [duplicate]

jquery,css,styles
This question already has an answer here: jQuery check if element has a specific style property defined inline 4 answers For example given two divs like this: .example{ width: 200px; height: 200px; z-index: 4; } <div id="first" style="height:100px;width:200px;z-index:5;">Hardcoded</div> <div id="second" class="example" >Css</div> How can i detect by jquery/javascript if,...

Styling Javafx with CSS

java,css,user-interface,javafx,styles
I have been working with javafx lately, and have started to work on styling the form. I have created a program that would create a weak encryption for your text, it isn't totaly done. Here is the java code - public class encryption extends Application { private static StringBuffer password;...

How would you bind a DataTrigger to a Child property from a resource-defined Style?

wpf,binding,styles,datatrigger
How can I style an element based on changes in child properties? I would accept a different approach, but the desired result is simply that the parent property is set a certain way as long as a a child property (IsPressed) is true. If we are styling one named item...

VS2013 Form: How can I disable style change on mouseover?

c#,forms,visual-studio-2013,styles
Visual Studio has a mandatory(?) style property 'mouseOverBackColor' that insists on changing the style of a button/checkbox. I would like the button to retain it's current style and ignore mouseEnter/Over/Leave events. Thanks....

curved style for image

html,css3,web,styles
How to design the curved style for the image in 3d! The original image has to be show like below image. Because In 3d rotation I need to show it in dynamically like the below image. For editing in Photoshop for each image has take much time so it need...

“Use Theme.AppCompat theme with this activity” Exception

android,android-actionbar,styles,themes
I used recently Android Asset Studio to generate a custom Action bar theme for an app and when I placed everything in my project the app crashes with this exception: "java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity." Please if somebody has an idea why...

Add css to an ID in php

css,wordpress,styles
I'm working in wordpress, and I am having a bit of trouble. As you see: in the page "articles" managed with page.php, it shows the categories widget at this point (see image 1), Then, inside the page "articles", if you click in any subpage, managed by single.php, the categories widget...

How to change window style/theme in c++

c++,user-interface,styles,window,themes
I need an approach how to customize the window style like Steam or Spotify. I don't want to have the boring Windows (or any other OS) look. Can that be done with Qt or the WinApi? Do I need DirectX or OpenGL for doing that? Best Regards...

Inserting google map's script into html webpage

javascript,html,css,html5,styles
I was asked to edit webpage for my friend. I am not an IT specialist or computer master, but I can do some edits in html, php and js. I am trying to add the google's map script to this webpage, you can find the code here: http://pastebin.com/UDNZ4F4r. The thing...

Getting currently active menu title in wordpress

php,wordpress,menu,styles
I need to get currently active menu item (menu title like Home, About us, etc..) on each page in wordpress. I am using wordpress codes to display menu & it displayed correctly. Code is shown below, $menu_name = 'primary'; if ( ( $locations = get_nav_menu_locations() ) && isset( $locations[ $menu_name...

Align text in Excel cell with new line c#

c#,excel,styles,interop,excel-interop
How can I align the text in Excel when a cell has 2 lines? I tried this: for (int j = 1; j <= RowsCount; j++) { for (int i = 1; i <= 18; i++) { ws.Cells[j, i].Style.VerticalAlignment = Microsoft.Office.Interop.Excel.XlHAlign.xlHAlignCenter; ws.Cells[j, i].Style.HorizontalAlignment = Microsoft.Office.Interop.Excel.XlHAlign.xlHAlignCenter; } } But this works...

WPF: why my slider not show the minimum value on my label

wpf,slider,styles
<Grid Margin="405,192,170,450" > <Slider Name="speedSlider" Value="1" Style="{StaticResource SliderStyle}" HorizontalAlignment="Left" VerticalAlignment="Bottom" Minimum="0" Maximum=" 50" TickFrequency="5" TickPlacement="None" Width="160"/> <Label Name="lblSliderSpeed" Content="{Binding ElementName=speedSlider, Path=Value, UpdateSourceTrigger=PropertyChanged}" Grid.Column="1" VerticalAlignment="Bottom" HorizontalAlignment="Right" ContentStringFormat="{}{0:#}"/> </Grid> My label show the current slide...

Jssor slider variable width based on window width

css,slider,styles,width,jssor
It is possible to change slides to fixed width based on window size (media queries)? I don't want it to scale or be in percetange, just fixed width depending on window size. For example something like this @media screen and (min-width: 320px) { .slides { width: 200px; } } @media...

Style expander header background color in App.xaml

c#,.net,wpf,styles,expander
I'm trying to create a global style for Expander in WPF. This is what I achieved so far: <Style TargetType="Expander"> <Setter Property="HeaderTemplate"> <Setter.Value> <DataTemplate> <Border Background="Red"> <ContentControl Content="{Binding}" /> </Border> </DataTemplate> </Setter.Value> </Setter> </Style> And this is how it looks: Not very satisfying. Question: How can I change the background...

Android - Send email with styled HTML

android,html,colors,styles
I get a server response which provides us with HTML to be sent via gmail. This works fine on the iOS counterpart of the app, however the text just comes out as plain text in the Android application. Here is an example part of the response we get: <html> <p...

No resource found that matches the given name [email protected]:style/Widget.AppCompat.Light.ActionBar.Solid.Inverse'

android,xml,styles,android-manifest
Sorry for my english. I try change action bar collor. And i have this error: error: Error retrieving parent for item: No resource found that matches the given name [email protected]:style/ Widget.AppCompat.Light.ActionBar.Solid.Inverse'. I have minSdkVersion = 12 style.xml <resources xmlns:tools="http://schemas.android.com/tools" xmlns:android="http://schemas.android.com/apk/res/android"> <style name="MyTheme" parent="@android:style/Theme.Holo.Light"> <item name="android:actionBarStyle">@style/MyActionBar</item>...

Choose Style depending on property

c#,wpf,styles,datatrigger
Is it possible to set the Style Property (of a Button for example) from within a DataTrigger on the same control? I would like to define my Default-, MouseOver- and Selected-Styles as resources to reuse them later on. However handling MouseOver (and other) events seems to be usually done by...

Combining style attributes this way

html,css,styles
<!DOCTYPE html> <html> <body> <h1 >This is a heading</h1> <p style="color:blue" "font-size:300%">This is a paragraph.</p> </body> </html> Is it possible to combine two style attributes this way? How does one do that?...

styles css in embeded souncloud player

css,iframe,styles,embed,soundcloud
I am trying to make a small site I use embed code to display soundcloud music in webpage. however, I want to remove the orange button play and the player down my iframe . I am researching I found that I could do it with css, just hidden buttons ....

item radius shape android

android,xml,styles
Sorry for my English. I can not understand the work with of radius. I need to create a transparent figure in which to store the text. Below I have created a figure, but rounded corners at the top-left corner does not work <layer-list xmlns:android="http://schemas.android.com/apk/res/android"> <item android:top="-1dp" android:right="-1dp" android:left="-1dp" android:bottom="-1dp"> <shape>...

How can I have a TextBox style with properties of other TextBox style

wpf,styles
I made an TextBox style but now i need some differences for example an other corner radius. This is my default style: <Style TargetType="TextBox"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type TextBoxBase}"> <Border CornerRadius="10" Padding="2" Background="{DynamicResource DefaultItemBGBrush}" BorderBrush="#C2C2C2" BorderThickness="1" > <ScrollViewer Margin="0" x:Name="PART_ContentHost" FontWeight="Bold" Foreground="#8D8D8D"/> </Border> </ControlTemplate>...

Why font-size is not applied to raw cell content

html,css,styles
I have class definition: .small, td.small, td.small > nobr, td.small > a { font-size: 90%; } That makes text inside of anchor in the cell looking smaller. But style is not applied if I put text in cell without anchor. <table> <tbody> <tr> <td class="small"> <a href="...">Small content</a> </td> <td>Should...

How do I convert font style to font weight in Java?

java,fonts,javafx,styles,weight
I want to set a specific ont to a Text within a TextFlow in JavaFx. However, Font has only static .font() methods, which expects a FontWeight instance. How do I convert a font style like "Regular" to a FontWeight instance? There is no "Regular" in the final fields of Font....

Style only one anchor link with class applied to li

css,styles,stylesheet
Struggling with this one but I'm sure it's quite easy! WordPress is applying a class "current_page_item" to the <li> that surrounds my anchor link in my side menu. I want to bold the current page item only. I have some sub menus being nested like so: <ul class="menu"> <li class="current_page_item">...

Style div display table-row can be styled or not

html,css,html5,css3,styles
I have a CSS table using divs only, I need to set style to the div ROW like this: <div style="display:table;width:100%;height:80px"> <div style="display:table-row;width:100%;height:80px; background:#333"> <div style="display:table-cell;width:200px;height:auto"> 1 </div> <div style="display:table-cell;width:auto; height:auto"> 2 </div> <div style="display:table-cell;width:200px;height:auto"> 3 </div> </div> more rows and tds in CSS </div> Questions: 1.- because div display...

CSS background elements on both sides of the screen

html,css,background,styles
I want to achieve this: two decoration elements (sort of waves) on both sides of the screen. Here's what I've got so far. If more elegant solution is possible (like styling with CSS only body element), then please advise. Below solution would be fine, if both < img > elements...

Is it possible to add a class and a style to a Razor element

css,razor,model-view-controller,styles
Is it possbile to add a style AND a class atrribute to a Razor element. <div style="width:170px;float:left;"> @Html.DropDownListFor(m => m.SelectedPremise, Model.PremiseList, "Please select", new { @class = "selectpicker", data_style="btn-primary" ,style="width:100px;"}) </div> This does not work......

Applying some styles to control

java,android,xml,styles
As you know in html/css you may apply some classes (and hence some styles) to the tag. It is cery convenient and i would like to have tgis opportunity in android development. Is there a way to apply some styles to one control?

Base.Widget.AppCompat.Button vs Widget.AppCompat.Button

android,styles,appcompat
I´m Using AppCompat 22.1.1 What´s the difference between Base.Widget.AppCompat.Buttonand Widget.AppCompat.Button ?...

WPF style button

c#,wpf,xaml,styles
I've tried to change style for mouseover event. Here's my styles code: <Window.Resources> <Style x:Key="NavigationButton" TargetType="{x:Type Button}"> <Setter Property="Background" Value="#295fa6"/> <Setter Property="BorderBrush" Value="{x:Null}"/> <Style.Triggers> <Trigger Property="IsMouseOver" Value="True"> <Setter Property="Background" Value="Red"/> <Setter Property="BorderBrush" Value="{x:Null}"/> </Trigger> </Style.Triggers> </Style> </Window.Resources>...

ExtJS: displayfield with same style as textfield

css,extjs,styles
I'm using xtype displayfield for fields which act as link and displayfield renders html ok. It works fine. I would like to use a same style for displayfield as for textfield (especially because of border). Could you tell me the simplest way to achieve it? I've tried fieldCls, baseCls etc....

Multiple white space in html

html,styles,whitespace
I would like to ensure that my chords above words are separated nicely by multiple white space. The issue is that when I use pre, it comes out pre-formatted and hence not what I wanted. Also, with &nbsp;, the code looks very ugly. What is the best method to solve...

How to style object when the user clicks it

html,css,styles
In css for the links I can style the as before user clicks and after user clicks. But how can I do this for simple text or an object that when a user clicks that object then change its color. For Example <style> .object:onmouseclick { background-color:green; padding:5px; } </style> What...

Change the style of content dialog button in windows phone universal application

styles,windows-phone-8.1,win-universal-app
I have this content dialog box defined inside my xaml: <ContentDialog x:Name="AlertMessage" Background="#363636" IsSecondaryButtonEnabled="True" SecondaryButtonText="Cancel" IsPrimaryButtonEnabled="True" PrimaryButtonText="Ok" > <ContentDialog.Content> <StackPanel Name="rootStackPanel" Height="Auto" > <StackPanel Margin="0"> <StackPanel Margin="0,0,0,10" Orientation="Horizontal"> <TextBlock x:Name="HeadingText" x:FieldModifier="public" Style="{StaticResource ApplicationMessageBoxHeadingStyle}"...

How to change the background color of a TextView inside of an ActionMode

android,android-actionbar,styles,android-actionmode
I have a TextView inside of my action bar, like the following: I have logic configured to make it overlay the Toolbar with an ActionMode when I long-press on an item in the associated ListView. This ends up looking like the following: This is basically correct, except for the annoying...

No Parenthesis in Rails - Good Style? [closed]

ruby-on-rails,ruby,styles
When I first started with ruby/rails and noticed that you don't need to put parenthesis, I recall thinking "no way I'll do that!". But now I kind of like it. So the question is, is that good style? Or should I stick to using parenthesis? Thanks....

How to style Bootstrap menu like a V? [closed]

css,twitter-bootstrap,menu,styles
Is it possible to style the menu like this (see link http://i.stack.imgur.com/Z5YB6.jpg) in Bootstrap using CSS? How to I do? Thank you in advance!...

jTextPane color with some exception in chat

java,swing,styles,chat,jtextpane
I am using jTextPane to use sender and receiver chat color. All works fine but [email protected] every chat message. here Jhon is revceiver and peter is sender here peter is revceiver and Jhon is sender may be I m doing some mistake in code. Here is the code for Sender...

Android - Overriding a Style per Theme

android,styles,android-theme,android-styles
Is there a way to change a style based on what theme is is set on an activity? for example, suppose my activity has a textview with a style set to TextViewStyle <TextView style="@style/TextViewStyle" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Text"/> This is my TextViewStyle <style name="TextViewStyle" parent="android:style/Widget.TextView"> <item name="android:textStyle">bold</item> <item name="android:textSize">8sp</item> <item...

WPF style info from external text file

wpf,vb.net,styles
Not sure if this is possible, but I have a WPF application that now has a requirement to be skinnable. Basically, this equates to several key colours and a couple of logos. Is there any way of grabbing the hex values for the colours in defined styles from an external...

Remove Combobox winrt flayout heading

combobox,windows-runtime,styles,winrt-xaml
In winrt windows phone app when you have more than 5 items in a combobox, it opens up on a full screen. And on top its written 'Choose an item'. I want to remove this heading from all my combo boxes....

WPF: Bind to property of a parent element

c#,wpf,xaml,binding,styles
I'm using a DataGrid and would like to introduce a style trigger for cells that sets the background color of the cell depending on the column's IsReadOnly property. I think there is some way to get from the cell level to the column level using RelativeSource (navigating all the way...

Changing styles in Word using vba

styles,word-vba
I am very new to programming, so forgive my ignorance. I am trying to create specific headings in a document that does not have any or has different heading styles assigned. What precedes the text in the headings are numbers. The numbers are specific and essentially represent the content of...

Style “Cannot find resource 'MetroCheckBox'” in MahApps

c#,wpf,xaml,styles,mahapps.metro
I'm starting to use styles in WPF. I'm using MahApps styles as a base, which so far has been really good. I've been able to make specific modifications using the BasedOn property. One of the simpler changes is to add a default margin so when adding controls they don't touch....

DataGridView freezes when loading content and style C#

c#,winforms,datagridview,styles,freeze
My form has 6 dataGridViews in different tabs of a tab Control, the user is able to enter values and change the cell backcolor, with a save button, the values for each dataGridView are saved into a text file, same with the backcolor of the cells in each dataGridView. When...

How to set a borderless button which changes its color when mouse hovering in WPF

c#,wpf,xaml,button,styles
I want to override all my button's style to a borderless grayish button which highlights when hover on. I wrote like below: If I remove the template section (I even have no idea of what does it do), the button will have a border even if I have set BorderThickness...

PHP String for HTML style

php,html,css,string,styles
I want to show a png file in background of a div. I have this CSS style for put it in the correct place. I'v tested directly in my HTML and the style works properly. I't doesn't work wen I use php variable. <?php if ($RScoluna1['nova'] == 1){ $style =...

Scala “Sentence-Like” Function Definition [duplicate]

function,scala,styles
This question already has an answer here: When to use parenthesis in Scala infix notation 4 answers I am refactoring some code and wanted to learn how Scala methods are written so that they can be written like: foo = Map("Hello" -> 1) foo contains "Hello" where "contains" is...

How to base a style on an inherited style

c#,wpf,styles
So I have a Master Detail page. And in my Master page I have a style that will set the style for all buttons. Master Page <Style TargetType="Button"> <Setter Property="Background" Value="White" /> <Setter Property="TextBlock.TextAlignment" Value="Center" /> <Setter Property="RenderTransformOrigin" Value="-0.893,-11.7"/> <Setter Property="VerticalAlignment" Value="Center"/> </Style> in my Detail Page I have a...

how to remove blank space from web page? [duplicate]

html,css,css3,styles
This question already has an answer here: HTML: white space around elements, how to remove? 2 answers I Have one Problem by web page design.can't remove this space from page! by this style: <body> <div style="width:100%;" > ss </div> please see this picture of my page: ...

while Inherit style in WPF it affect parent style

c#,xaml,styles,wpf-controls
In WPF i have a style for the control like below, <Style TargetType="local:CustomControl"> <Setter Property="Background" Value="Transparent" /> <Setter Property="BorderBrush" Value="Gray" /> <Setter Property="BorderThickness" Value="0,0,0,1" /> <Setter Property="Padding" Value="3,0,3,0" /> <Setter Property="IsTabStop" Value="False" /> <Setter Property="VerticalContentAlignment" Value="Center" /> </Style> Now i need to override customcontrol border for some other place like...

Is there something like style group?

android,styles,themes
I have two group of views which should use different styles, just call them leftStyles and rightStyles. the two group of views have the same layout.xml , I want to programly change the "styleGroup" of the container to change all it's children's style, just like a theme. Did it exist...

Nested Styles in WPF

c#,wpf,styles
I would like to nest Styles in WPF. I have a resource dictionary: <Style x:Key="BottomButtonBar" TargetType="{x:Type Grid}"> <Style TargetType="{x:Type Button}"> <Setter Property="Margin" Value="10,2" /> <Setter Property="Width" Value="90" /> </Style> <Style TargetType="{x:Type TextBlock}"> <Setter Property="HorizontalAlignment" Value="Center" /> <Setter Property="VerticalAlignment" Value="Center" /> <Setter Property="Margin" Value="2,0"/> </Style> </Style> What I want is: If...

JS: Cannot read property 'style' of null

javascript,styles
(Sorry for my aplogize, I got some mistake, just updated the new code again.) I have the following code,and Chome throws"Uncaught TypeError: Cannot read property 'style' of null" to the console: function gen_mainTable(){ var code = ""; code +='<table width="100%" border="1" cellspacing="0" cellpadding="4" align="center" class="FormTable_table" id="mainTable_table">'; code +='<tr><td class="CL">SELECT</td><br><td colspan="2"...

How to change ActionBar menu background color (android 4 & 5)

android,menu,android-actionbar,styles,background-color
I've got one trouble while changing android design. I need to change action bar menu background color to black. I know, there are lots of answers for this question. I tried many of them. But nothing worked for me. Oh, and i forgot to say, that i am not a...

(AngularJS) Only one less file for entire Website

css,angularjs,styles,less
I am a beginner with AngularJS and I have a little problem, I installed grunt-contrib-less to support less files instead css but now I have to declare all less styles that will be compiled into only one css file. But my problem is normally when I'm using less, I write...

How to make both ListViewItem's template style and ListView.ItemTemplate working?

wpf,xaml,listview,styles
I have the code below in my App.xaml. I override the template to make the background stays the same as transparent when I click/hover on a ListViewItem. <Style TargetType="{x:Type ListViewItem}"> <Setter Property="Background" Value="Transparent" /> <Setter Property="Height" Value="{StaticResource RowHeight}"/> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ListViewItem}"> <Border BorderBrush="Transparent" BorderThickness="0" Background="{TemplateBinding Background}">...

How do I apply CSS style to ASCII character

html,css,styles,ascii,weight
I'd like to reduce the weight of a my ascii degree character &deg; in my html document. Does anybody know how? HTML: <html> <body> <table> <tr> <td> <div style="position:absolute; top: 70; right: 0;"> 72 <span>&deg;</span> F </div> </td> </tr> </table> </body> </html> CSS: body { height: 100%; font-weight: 400; color:...

IPAD Mini - IOS 7.0 - Double Select Box Overlap

css,layout,styles,ipad-mini
I have two select boxes as show on the image above. Now the issue is that when I click on the year field, the month field is still being triggered. Seemed like the area for the first select box is too wide or there is some kind of overlap....

WPF Button Background when IsEnabled = False

wpf,button,styles
I try to set a style for my button when it is not enabled so that the Background LinearGradientBrush is similar to the one set for the button when it is enabled. I have tried with Triggers but it seems that only the text Color is changing: <Application x:Class="RSPolar.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"...

The position of int main() function [closed]

c++,function,styles,main,writing
I know that it's possible to write a code in that way: void foo() {...} void bar() {...} string qix(){...} int main() { //functions calling } And also it's possible to write the same like: /* function's prototypes here*/ int main() { //functions calling } void foo() {...} void bar()...