style

Javascript: How can I undo the setting of element.style?

I have an element in my document that has a background color and image set through a regular CSS rule. When a certain event happens, I want to animate that item, highlighting it (i'm using Scriptaculous, but this question applies to any framework that'll do the same). new Effect.Highlight(elHighlight, { startcolor: '#ffff99', endcolor:...

Is usage of anonymous classes in Java considered bad style or good?

I know anonymous classes save typing, if it comes to implementing Listener and similar stuff. They try to be a replacement for some usages of closures. But what does the community think about the value of these language-feature? Does it make sense and you use it regularly? Makes the saved typing the code clearer, more understandable and...

Changing the style of a Combo-Box in WPF (in Blend preferably)

I'm having some issues trying to change the look / style of a combo box in Expression Blend / WPF. While there are tutorials out there describing setting styles for buttons, there seem to be a few wrinkles with ComboBox controls. Can anyone offer any advice, or point me towards good tutorials that cover re-styling something more comple...

What's wrong with my javascript? Fading images

Hello, I'm trying to make Javascript change the style of certain DIV IDs by changing their background every few seconds. Basically, a fading header...here's my code, and it just doesn't change the background, at all. How do you call a function? http://pixolia.net/sandbox/morph/index.php ...

CSS Styling the prompt tooltips in dojo

Does anyone know the name of the CSS classes responsible for styling the dojo promptMessages (or invalidMessages) tooltip associated with ValidationTextBoxes. Normally Firebug does a great job of revealing all the inner workings of CSS, but in this case the tooltip prompt disappears when I try to inspect it! I am intending to play with...

What are good resources for CSS templates or templated layout sites?

Does not have to be free, I'm just not a designer and loathe starting from scratch. Any suggestions would be appreciated. ...

How to fade the background

I was going to look up how to do this, but I don't really know what to call it to look it up, so I was hoping I could describe it here and someone could point me in the right direction. Anyways, I'm looking for how to make it so on a website, when you click on something, a new sorta layer pops up and fades the background. I see sites do ...

Can i get the key of a style in code-behind? (WPF)

If I have the following code: Style defaultStyle = (Style)FindResource("MyTestStyle"); Is there a way to get the name of the style (i.e. reverse-lookup)? Something like: string name = defaultStyle.SomeMagicLookUpFunction() Where name would evaluate to "MyTestStyle." Is this possible? ...

How do I match my controls' styles to the current theme? (WPF)

If I create a custom control with WPF, how can I provide styles for the control that match the currently applied theme (Aero, Luna, Classic, etc.)? For example I'd like to apply the following when using Aero: <Style> <Setter Property="Background" Value="White"/> </Style> But then apply a different style when using Luna: <Style> ...

Silverlight DataGrid styling

I have a DataGrid whose ItemsSource is bound to a changing Observable Collection. Inside of this collection is a Business Object. Based on some of the values of the Business Object's properties, I would like to be able to modify the color of the text for each item displayed in my DataGrid once the ItemsSource is created. Has anyone do...

Python plotting: How can I make matplotlib.pyplot stop forcing the style of my markers?

I am trying to plot a bunch of data points (many thousands) in Python using matplotlib so I need each marker to be very small and precise. How do I get the smallest most simple marker possible? I use this command to plot my data: matplotlib.pyplot( x , y ,'.',markersize=0.1,linewidth=None,markerfacecolor='black') Then I can look at...

Very Strange CSS problem on Internet Explorer. I have no idea what is wrong!

I have just been testing a web site I have set up in Internet explorer. Works fine in Firefox of course. I have a set of style sheets most of which have a background picture I, the user can select the different style sheets as they please. The style sheets render exactly the same apart from colours and backgrounds, of course the text bas...

instance variable/ method argument naming in Objective C

What conventions are people here following for naming of instance variables and method arguments - particularly when method arguments are used to set ivars (instance variables)? In C++ I used to use the m_ prefix for ivars a lot. In C# I followed the convention of disambiguating purely by use of this. for ivars. I've since adopted the e...

Styling a WPF layout grid background (of each cell, row, column)

I would like to know if there is any way to style a WPF layout grid's cells, rows and columns. I've been trying to find any information and the few mentions I've found have not been that informative. I would like to style the grid to look like the one in the linked screenshot. If the actual control does not support it, can I inherit it...

How should I distinguish between subclasses

I have a token class that looks something like this: class Token { public: typedef enum { STRTOK, INTTOK } Type; virtual bool IsA(Type) = 0; } class IntTok : public Token { int data; public: bool IsA(Type t) { return (t == INTTOK); } int GetData() { return data; } } IntTok newToken; if ( newToken.IsA(Token::INTTOK ) {...

How can I use css 'ids' in combination with server controls in ASP.NET?

Hi, My designer created a stylesheet that makes heavy uses of id's. Example: <div id="globalheader"> <ul id="globalnav">.... css: #globalheader { width: 715px; height: 100px; margin: 18px auto; position: absolute; top: 0; left: 20; z-index: 9998; } #globalheader #globalnav { margin: 0; padding: 0; } #globalheader #globalnav li { dis...

Different style on buttons in messagebox in different projects.

Hi! I have a problem with the style of the button in a messagebox. If I call the following line of code in a current project the button get one type of visual apperance/style. And If I create a new VB.NET Windows Application project it gets a standard Windows apperance/style. Windows.Forms.MessageBox.Show("Yaay", "Yaay!", Windows.Forms...

How to make a text box Visibility=Hidden with a trigger

I seem to be having a hard time today. All I want to do is make a TextBox hidden of visible based on a bool value databound to the Window its hosted in. What I have just won't compile and I don't understand why. Please help. <TextBlock Grid.Column="2" Text="This order will be sent to accounting for approval" Foreground="Red" Vertical...

WPF UserControl Style

I want to set the background property of all the usercontrols of my project. I tried with <style TargetType={x:Type UserControl}> <setter property="Background" Value="Red" /> </style> It compiles but didn't work. ¿Any Idea? Thanks! ...

How do I make a marquee progress bar in WPF?

In Winforms I could set the ProgressBarStyle of a progress bar to Marqee, and that would have the progress bar incriment on its own without having to be set, for processes where I don't know how long its going to take, and no good way to report back to the UI. I would like to do the same in WPF, but I can't find a way to pull it off sho...