Search Results

Search found 1524 results on 61 pages for 'styles'.

Page 3/61 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Commenting/In-Code Documentation Styles

    - by Maxpm
    This might be a stupid question, but it's been in the back of my head for a while and I can't find a decent answer anywhere else. I have a teacher who says we should explicitly list each parameter with a description, even if there's only one. This leads to a lot of repetition: double MyFunction(const int MyParam); // Function: MyFunction // Summary: Does stuff with MyParam. // Input: int MyParam - The number to do stuff with. // Output: MyParam with stuff done to it. When writing in-code documentation, how detailed are you?

    Read the article

  • Learning to program styles? [closed]

    - by MrNewbProgrammer
    I'm a beginner programmer and I am currently developing an application of my own, just for the fun of it and learning to program. I'm building it from scratch, because I think that in this way I will learn the most. I have stumbled upon MVC's and CMS, CodeIgniter really got my attention, and the basic use is very straight forward. But I do not understand the inner workings completely. So I have decided that it might be better to just develop from scratch and maybe return to codeIgniter later, was that good decision? Would it be better to use CodeIgniter and learn from that?

    Read the article

  • Reducing WPF binding boilerplate with styles - updating the bindings themselves via styling?

    - by Eamon Nerbonne
    I'm still learning the WPF ropes, so if the following question is trivial or my approach wrong-headed, please do speak up... I'm trying to reduce boilerplate and it sounds like styles are a common way to do so. In particular: I've got a bunch of fairly mundane data-entry fields. The controls for these fields have various properties I'd like to set based on the target of the binding - pretty normal stuff. However, I'd also like to set properties of the binding itself in the style to avoid repetitiveness. For example: <TextBox Style="{StaticResource myStyle}"> <TextBox.Text> <Binding Path="..." Source="..." ValidatesOnDataErrors="True" ValidatesOnExceptions="True" UpdateSourceTrigger="PropertyChanged"> </Binding> </TextBox.Text> </TextBox> Now, is there any way to use styling - or some other technique to write the previous example somewhat like this: <TextBox Style="{StaticResource myStyle}" Text="{Binding Source=... Path=...}/> That is, is there any way to set all bindings that match a particular selection (here, on controls with the myStyle style) to validate data and to use a particular update trigger? Is it possible to template or style bindings themselves? Clearly, the second syntax is much, much shorter and more readable, and I'd love to be able to get rid of other similar boilerplate to keep my UI code comprehensible to myself :-).

    Read the article

  • WPF: Is it possible to add or modify bindings via styles or something similar?

    - by Eamon Nerbonne
    I'm still learning the WPF ropes, so if the following question is trivial or my approach wrong-headed, please do speak up... I'm trying to reduce boilerplate and it sounds like styles are a common way to do so. In particular: I've got a bunch of fairly mundane data-entry fields. The controls for these fields have various properties I'd like to set based on the target of the binding - pretty normal stuff. However, I'd also like to set properties of the binding itself in the style to avoid repetitiveness. For example: <TextBox Style="{StaticResource myStyle}"> <TextBox.Text> <Binding Path="..." Source="..." ValidatesOnDataErrors="True" ValidatesOnExceptions="True" UpdateSourceTrigger="PropertyChanged"> </Binding> </TextBox.Text> </TextBox> Now, is there any way to use styling - or some other technique to write the previous example somewhat like this: <TextBox Style="{StaticResource myStyle}" Text="{Binding Source=... Path=...}/> That is, is there any way to set all bindings that match a particular selection (here, on controls with the myStyle style) to validate data and to use a particular update trigger? Is it possible to template or style bindings themselves? Alternatively, is it possible to add the binding in the style itself? Clearly, the second syntax is much, much shorter and more readable, and I'd love to be able to get rid of other similar boilerplate to keep my UI code comprehensible to myself :-).

    Read the article

  • Automatic (keyless) styles not applied when in a MergedDictionaries in another assembly

    - by Catalin DICU
    I moved the styles and templates xaml files form my application (.exe) project to a library project (.dll) because I want to use them in multiple applications. In App.xaml I have: <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="pack://application:,,,/MyApplication.Common;component/Resources/All.xaml" /> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> </Application.Resources> In All.xaml (in the Common assembly) : <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Styles.xaml" /> <ResourceDictionary Source="Templates.xaml" /> <ResourceDictionary Source="Converters.xaml" /> </ResourceDictionary.MergedDictionaries> With this code keyless styles in Styles.xaml aren't applied. Instead, if I reference them directly in App.xaml, it works : <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="pack://application:,,,/MyApplication.Common;component/Resources/Styles.xaml" /> <ResourceDictionary Source="pack://application:,,,/MyApplication.Common;component/Resources/Templates.xaml" /> <ResourceDictionary Source="pack://application:,,,/MyApplication.Common;component/Resources/Converters.xaml" /> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> </Application.Resources> Can anyone explain why it happens ?

    Read the article

  • TabRenderer with no visual styles enabled?

    - by DxCK
    I want to draw a custom TabControl with custom functionality. To do this, i inherited the Panel class and overrided OnPaint method to draw with TabRenderer class. The problem is that TabRenderer working only when visual styles enabled (can be checked with TabRenderer.IsSupported), but what should i do if visual styles disabled? In this case, I thought using the ControlPaint class to draw tabs without visual styles, but it has no draw method related to Tabs. I want it basically to behave visually like the regular TabControl.

    Read the article

  • Excel 2007 Constantly Creating Custom Cell Styles

    - by Nick
    Hello, I've been using Office 2007 for a few months now and have noticed that it was creating duplicate custom cell styles on its own, like Normal 2, Normal 3, etc. It didn't really bother me at first, but now Excel will lag when I open the cell styles menu as it gathers well over a hundred of these duplicates (I have seen Normal 54 and Normal 5 2 2 so I'm unsure as to how many there actually are). I have also just checked a fresh Excel sheet, and it only has the defaults, but one I created earlier today from scratch has the Normal 54 listed. My questions are: Why is this happening? Can I delete a temp or custom settings file somewhere to clear this? Any help on this is appreciated.

    Read the article

  • Eclipse doesn’t recognize style in the Android Layout builder?

    - by Artem Russakovskii
    Since Android supports styles and it's good practice to use them (similar to CSS), I made a new style and applied it to 3 buttons. The Layout builder in Eclipse did not register the changes and either broke (showed nothing) or didn't apply styles at all. After running the app in the emulator, styles are correctly applied. So is there something I'm missing or the Android plugin doesn't support styles?

    Read the article

  • How to apply styles to all windows in WPF app?

    - by Brandon
    I have the following App.xaml file: <Application x:Class="MiniDeviceConfig.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" StartupUri="MiniDeviceConfig.xaml"> <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Button.xaml"/> <ResourceDictionary Source="CheckBox.xaml"/> <ResourceDictionary Source="ComboBox.xaml"/> <ResourceDictionary Source="Common.xaml"/> <ResourceDictionary Source="GroupBox.xaml"/> <ResourceDictionary Source="Label.xaml"/> <ResourceDictionary Source="LinkButton.xaml"/> <ResourceDictionary Source="ListBox.xaml"/> <ResourceDictionary Source="ListView.xaml"/> <ResourceDictionary Source="RadioButton.xaml"/> <ResourceDictionary Source="Tooltip.xaml"/> <ResourceDictionary Source="Window.xaml"/> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> </Application.Resources> In my application, my main window is MiniDeviceConfig.xaml (as seen above). In my Button.xaml file, I clearly set the button height to some obscene number. And, this size is reflected in my main window's buttons. However, some action on the main window triggers a modal window that has more buttons on it. I was expecting the same tall buttons but no such luck. How do I get the style to propagate into all windows in the application?

    Read the article

  • GWT styles not applying

    - by sernaferna
    I'm creating a GWT application that uses UiBinder, and I've come across a bizarre problem where styles aren't applying to my elements--until I refresh the browser, and then the styles briefly get applied, in that fraction of a second before the page refreshes. In other words: Open page; none of my defined styles are used. Hit Refresh For a fraction of a second the styles are used, before the page goes blank The page reloads, without the styles again I'm going to include my entire *ui.xml file, because it's not too big. <!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent"> <ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder" xmlns:g="urn:import:com.google.gwt.user.client.ui"> <ui:style> .idLabelStyle { font-weight: bold; text-align: center; width: 100px; border-style: solid; border-width: 1px; margin-right: 5px; } .nameLabelStyle { font-weight: bold; text-align: center; width: 500px; border-style: solid; border-width: 1px; margin-right: 5px; } .addressLabelStyle { font-weight: bold; text-align: center; width: 500px; border-style: solid; border-width: 1px; } </ui:style> <g:HTMLPanel> <g:HorizontalPanel> <g:Label addStyleNames="{style.idLabelStyle}">ID</g:Label> <g:Label addStyleNames="{style.nameLabelStyle}">Name</g:Label> <g:Label addStyleNames="{style.addressLabelStyle}">Address</g:Label> </g:HorizontalPanel> </g:HTMLPanel> </ui:UiBinder> I really hope I'm missing something simple.

    Read the article

  • Are there predifined styles for making arrow buttons in windows phone 7?

    - by Micah
    I want to make some buttons in my app that look like the common round buttons with the arrows found all over the win 7 apps. Anyone know where I can find resources for these? UPDATE Here's a great tutorial on creating round buttons in WP7. This is exactly what I was trying to do, but I will use the images mentioned by John Gardner below: http://blogs.msdn.com/b/priozersk/archive/2010/08/13/creating-round-button-for-wp7-part-1.aspx http://blogs.msdn.com/b/priozersk/archive/2010/08/14/creating-round-image-button-for-wp7-part-1.aspx Thakns!

    Read the article

  • ASP.NET MVC 2 relative paths for scripts and styles

    - by Tomaszewski
    Hi, having this really silly problem in ASP.NET MVC 2 with .NET 4. I need to test other pages using localhost, but sometimes I need to show the page to some else on another computer and so need to path out to my machine. In doing so, I need to use relative paths for my and tags. When I test through VS, I use relative path: <script src="../../Scripts/somejavascript.js"></script> <link href="../../Styles/somestyle.css" /> However, when I publish to local IIS, I'm having all sorts of problems beacuse the Scripts and Styles folder are at the same directory level, but it seems like I have to path out differently. For example, in the scenario above the styles will be picked up but the JavaScript won't be. Any ideas on how best to path out, relatively using MVC 2?

    Read the article

  • styles/style.css No mapping found for HTTP request

    - by sonx
    Hi, it seems my styles folder added under the web folder is not getting mapped by dispatcher servlet on my JSP's. I get WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/onlinebasket/styles/style.css] in DispatcherServlet with name 'onlinebasket' here's my dispatcher servlet <servlet-mapping> <servlet-name>onlinebasket</servlet-name> <url-pattern>/</url-pattern> </servlet-mapping> and i this is my CSS URL on JSP <link rel="stylesheet" href="<c:url value="/styles/sytle.css"/>" type="text/css"/> This folder is on the web folder.

    Read the article

  • Add multiple Styles to Silverlight Control

    - by lidermin
    Hello, I'm using silverlight and I defined two styles for the page: ExpanderBottomRightButtonStyle ExpanderScaleStyle Now I want to add those two styles to the same control: <controls:Expander x:Name="expBRButton" Grid.Row="1" Grid.Column="2" Margin="5" Style="{StaticResource ExpanderBottomRightButtonStyle}"> <controls:Expander.Content> <Button Content="&lt;Button&gt;"></Button> </controls:Expander.Content> </controls:Expander> I don't want to join the two styles in one, cause I need them separately too. I thought something like: Style="{StaticResource ExpanderBottomRightButtonStyle ExpanderScaleStyle}" But it's not possible. How should I do this? I'm new on Silverlight 3. Thanks in advance.

    Read the article

  • Use cell formatting (e.g. "Good", "Bad", "Neutral") in formulas?

    - by ngm
    I am compiling a comparison of different pieces of software in an Excel spreadsheet. It is a big long list of features (the rows), with each column being one of the applications I'm evaluating. I've used styles to visually show how well each product meets each feature, as well as the importance of that feature, and now I'm wondering if there's a way I can use those annotations in a formula. The table is like: . | Product A | Product B | Product C Feature A | blah blah blah Feature B | blah blah blah Feature C | blah blah blah .... | .... | etc | Where I've put 'blah' in the table above, in my actual spreadsheet is (potentially lengthy) descriptive text explaining something about this feature in the given product. I've then used the styles "Good", "Neutral" and "Bad" to visually annotate the description, to show how well each product meets that feature. For each feature I've also used the styles Accent4, 60% Accent4, 40% Accent4, etc, to annotate the importance of each feature. Now I'm wondering if somehow I can use those styles (the annotations) to tot up a total score for each product. e.g., Score for feature A = valueof(60% Accent4) * valueof(Good) Is it possible at all?

    Read the article

  • Menu Control in Master Page fails to use CSS styles

    - by Shaun
    I'm working on a web application that uses ASP.NET 3.5 and C#. Structurally, I have a master page with a menu control on it. The control serves as my navigation, and it gets its items from a SiteMapDataSource control and a corresponding Web.sitemap file. The problem is that some styles do not render properly when you specify the CssClass property. More specifically, the selected and hover styles don't respond to css styles. Consider the code below: <%@ Master Language="C#" AutoEventWireup="true" CodeFile="Site.master.cs" Inherits="Site" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.or/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>A webpage</title> </head> <body> <form id="form1" runat="server"> <div id="page"> <asp:Menu ID="navMenu" Orientation="Horizontal" StaticMenuStyle-CssClass="staticMenu" StaticMenuItemStyle-CssClass="staticMenuItem" StaticSelectedStyle-CssClass="staticSelectedItem" StaticHoverStyle-CssClass="staticHoverItem" runat="server"> </asp:Menu> <asp:SiteMapDataSource ID="srcSiteMap" runat="server" ShowStartingNode="false" /> <br /> <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server"> </asp:ContentPlaceHolder> </div> </form> </body> </html> Suppose I had a corresponding .css file with the following: .staticMenuItem { background-color:Red; } .staticSelectedItem { background-color:Green; } .staticHoverItem { background-color:Blue; } What will happen is that my item backgrounds will properly be red, but my selected item will not be green and the item I'm hovering my mouse over will not be blue. This seems true regardless of whether or not I include the style in the head of the master page or in an external file in default theme as specified in the web.config file. If I specify the styles in the asp.net xml like so: <asp:Menu ID="navMenu" Orientation="Horizontal" runat="server"> <StaticSelectedStyle BackColor="Green" Font-Underline="True" Font-Bold="True" /> <StaticHoverStyle BackColor="Gray" /> </asp:Menu> It appears to work properly in Firefox, but the style is never embedded in the html in Internet Explorer. Odd. Does anybody have any insight into what is causing this problem and how to neatly work around it? I'm aware I might be able to programmically determine the current page and select the corresponding menu item manually so it receives the proper style class, but before I resort to hacking C# and Javascript together to fix this functionality, I'm open to ideas.

    Read the article

  • Data Grid Styles Designer

    - by Kumar
    Looking for any decent grid styles designer with standard features such as select columns from a catalog Change the ordering of columns set column font/bold/italic etc. set column styles - fixed left / right etc. Have done it before but don't have access to that code Looking for any near ready to use sample before reinventing the wheel :) preferably winforms but can use wpf too

    Read the article

  • Different CSS Styles

    - by Nimbuz
    /* Style 1 */ .myclass { background:#ff0; border:1px solid #ff0 } #myid { width:80px; height:80px; } /* Style 2 */ .myclass { background:#ff0; border:1px solid #ff0 } #myid { width:80px; height:80px; } I'm sure there must be more styles for writing CSS, I'd like to know what are they. Is there an article already written that lists all styles. Thanks

    Read the article

  • CSS styles gone after Ajax call in IE 7

    - by roman m
    I've had a problem with my styles not being applied after AJAX calls. My styles were not in the < HEAD section of the page, and they were only recognized by IE on initial Page_Load. If you know of any other ways to fix this problem, post them here. This is more of a reference, hope this helps some people.

    Read the article

  • WPF Some styles not applied on DataTemplate controls

    - by Martin
    Hi, I am trying to learn something about WPF and I am quite amazed by its flexibility. However, I have hit a problem with Styles and DataTemplates, which is little bit confusing. I have defined below test page to play around a bit with styles etc and found that the Styles defined in <Page.Resources> for Border and TextBlock are not applied in the DataTemplate, but Style for ProgressBar defined in exactly the same way is applied. Source code (I just use Kaxaml and XamlPadX to view the result) <Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> <Page.Resources> <Style TargetType="{x:Type Border}"> <Setter Property="Background" Value="SkyBlue"/> <Setter Property="BorderBrush" Value="Black"/> <Setter Property="BorderThickness" Value="2"/> <Setter Property="CornerRadius" Value="5"/> </Style> <Style TargetType="{x:Type TextBlock}"> <Setter Property="FontWeight" Value="Bold"/> </Style> <Style TargetType="{x:Type ProgressBar}"> <Setter Property="Height" Value="10"/> <Setter Property="Width" Value="100"/> <Setter Property="Foreground" Value="Red"/> </Style> <XmlDataProvider x:Key="TestData" XPath="/TestData"> <x:XData> <TestData xmlns=""> <TestElement> <Name>Item 1</Name> <Value>25</Value> </TestElement> <TestElement> <Name>Item 2</Name> <Value>50</Value> </TestElement> </TestData> </x:XData> </XmlDataProvider> <HierarchicalDataTemplate DataType="TestElement"> <Border Height="45" Width="120" Margin="5,5"> <StackPanel Orientation="Vertical" Margin="5,5" VerticalAlignment="Center" HorizontalAlignment="Center"> <TextBlock HorizontalAlignment="Center" Text="{Binding XPath=Name}"/> <ProgressBar Value="{Binding XPath=Value}"/> </StackPanel> </Border> </HierarchicalDataTemplate> </Page.Resources> <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center"> <StackPanel Orientation="Vertical" VerticalAlignment="Center"> <Border Height="45" Width="120" Margin="5,5"> <StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center"> <TextBlock HorizontalAlignment="Center" Text="Item 1"/> <ProgressBar Value="25"/> </StackPanel> </Border> <Border Height="45" Width="120" Margin="5,5"> <StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center"> <TextBlock HorizontalAlignment="Center" Text="Item 2"/> <ProgressBar Value="50"/> </StackPanel> </Border> </StackPanel> <ListBox Margin="10,10" Width="140" ItemsSource="{Binding Source={StaticResource TestData}, XPath=TestElement}"/> </StackPanel> </Page> I suspect it has something to do with default styles etc, but more puzzling is why some Styles are applied and some not. I cannot find an easy explanation for above anywhere and thus would like to ask if someone would be kind enough to explain this behaviour in lamens' terms with possible links to technical description, i.e. to MSDN or so. Thanks in advance for you support!

    Read the article

  • Strange issue with fixed form border styles in Vista

    - by Nazgulled
    My previous post about this issue didn't got too many answers and it was kinda specific and hard to understand. I think I've managed to understand the problem better and I now believe it to be a Vista issue... The problem lies on all types of fixed border styles like FixedDialog, Fixed3D, FixedSingle and FixedToolWindow. It does not happen on the sizable ones. This problem, like I said, it also happens only on Vista. Let's say you have a form with any of the fixed border styles and set the starting location to 0,0. What you want here is for the form to be snapped to the top left corner of the screen. This works just fine if the form border style is one of the sizable options, if it's fixed, well, the form will be a little bit outside of the screen working area both to the left and top. What's more strange about this is that the form location does not change, it sill is 0,0, but a few pixels of the form are still drawn outside of the working screen area. I tested this on XP and it didn't happen, the problem is Vista specific. On XP, the only difference was the border size that change a bit between any of the styles. But the form was always perfectly snapped to position 0,0. If possible, without finding how many pixels are being drawn outside of the working area and then add that to the form location, is there a possible way to fix or workaround this?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >