background preloader

CSS Reference

CSS Reference

Немного об интерфейсах в .Net (по мотивам одного интервью) В прошедний понедельник мне посчастливилось попасть на собеседование на Senior .Net Developer в одну международную компанию. Во время собеседования мне предложили пройти тест, где ряд вопросов был связан с .Net. В частности в одном из вопросов надо было дать оценку (истина/ложь) ряду утверждений, среди которых было и такое: В .Net любой массив элементов, например int[], по умолчанию реализует IList, что позволяет использовать его в качестве коллекции в операторе foreach. Быстро ответив на этот вопрос отрицательно и отдельно дописав на полях. что для foreach необходима реализация не IList, а IEnumerable, я перешел к следующему вопросу. Про IList я смутно помнил, что этот интерфейс дает мне IEnumerable, индексатор и свойство Count, содержащее число элементов коллекции, а также еще пару редко используемых свойств, типа IsFixedCollection(). Класс System.Array var v = new int[] { 1, 2, 3 }; var t = v.GetType(); var i = t.GetInterfaces(); foreach(var tp in i) Console.WriteLine(tp.Name); 2.

Object Oriented CSS · stubbornella/oocss Wiki CSS media queries: width versus device-width width versus device-width In CSS media the difference between width and device-width can be a bit muddled, so lets expound on that a bit. device-width refers to the width of the device itself, in other words, the screen resolution of the device. Lets say your screen's resolution is 1440 x 900. The below shows the screen resolution and CSS media device dimensions of some of the popular devices out there: Just to complicate things even more, in iPhone and iPad devices, the device-width always corresponds to the width of the device in portrait mode, regardless of whether the device is in that mode or landscape instead. * For a more complete list of devices and their screen resolutions, visit this page. Lets see some more CSS media queries now that capture different devices and screen dimensions: /* #### Mobile Phones Portrait #### */ @media screen and (max-device-width: 480px) and (orientation: portrait){ /* some CSS here */ } So we now have a fairly good idea on using CSS media queries.

Alsacréations : Actualités et tutoriels HTML, HTML5, CSS, CSS3, standards du web CSS (Feuilles de style) Septembre 2016 Cours CSS Le concept de feuilles de style est apparu en 1996 avec la publication par le W3C d'une nouvelle recommandation intitulée « Cascading StyleSheets » (feuilles de style en cascade), notée CSS. Le principe des feuilles de style consiste à regrouper dans un même document des caractéristiques de mise en forme associées à des groupes d'éléments. Les feuilles de style ont été mises au point afin de compenser les manques du langage HTML en ce qui concerne la mise en page et la présentation. Elles sont appellées « feuilles de style en cascade » (en anglais « Cascading Style Sheets ») car il est possible d'en définir plusieurs et que les styles peuvent être hérités en cascade. Les feuilles de style permettent notamment : La recommandation CSS2, développé à partir de 1997, apporte un grand nombre de nouvelles fonctionnalités par rapport à la précédente norme (1.0), parmi lesquelles : La recommandation CSS4 est en cours d'écriture au W3C depuis 2010. Compatibilité des navigateurs

CustomSortOrder in SharePoint 2010 TermSets | Andrea Ramacciotti Blog's Be careful in using CustomSortOrder in SharePoint 2010 TermSets! TermSets terms can be ordered in custom way using the specific user inteface feature in Site Settings -> Term Store Management. That can be also used in code because Term class expose the CustomSortOrder property that’s a string where are listed all the term CLSID separated by “:”. Which is the problem? you remove one or more items, in the CustomSortOrder property still remains their CLSID. Be careful! Mi piace: Mi piace Caricamento... Galleria Questa voce è stata pubblicata in Computer e Internet, Sharepoint e contrassegnata con Sharepoint.

CSS Style Guides As we wrap up our recent poll on ordering CSS properties, it brings up the larger issue of CSS style guides. Ordering properties is just one choice you have to make that makes up a complete styling strategy. Naming is a part of it. Sectioning is a part of it. Commenting, indentation, overall file structure... it all makes up a complete CSS style guide. Let's round up some existing ones. But first... I love pattern libraries. The List I'll list some excerpts from each that I like below. GitHub GitHub CSS Style Guide → As a rule of thumb, don't nest further than 3 levels deep. Unit-less line-height is preferred because it does not inherit a percentage value of its parent element, but instead is based on a multiplier of the font-size. Google Google HTML/CSS Style Guide → Use ID and class names that are as short as possible but as long as necessary. E.g. E.g. .demo-image not .demoimage or .demo_image Idiomatic CSS Nicolas Gallagher's Idiomatic CSS → Configure your editor to "show invisibles". ThinkUp

CSS: fonts Font families After the color, the font is probably the most basic property of a page. On this page I won't show any "tricks," but I will show the range of font variations that CSS allows. Since not all fonts are available on all computers (there are thousands of fonts, and most are not free), CSS provides a system of fallbacks. The following table shows examples of various fonts (your browser may not know all of them) and you can see what your browser does with each of the five generic ones: Font styles Most fonts have various styles within the same family, typically a bold and an italic one, often also a bold italic style, somewhat less often a small-caps and in a few cases extra-light/extra-bold or stretched/condensed versions. The table below shows a number of different styles. The CSS Fonts Module has more properties to specify special styles (for fonts that provide several variants), in particular the font-variant property has many more values.

Lorem Ipsum - All the facts - Lipsum generator CSS Tutorial Ewen's Files, Ewen Elder; jQuery JavaScript PHP CSS xHTML MySQL Developer Setting the fixed width of a <select> element in Internet Explorer will cause all of the select options that are wider than the select's set width to be cropped. This jQuery plugin proposes a work around. Applying this plugin makes the select element in Internet Explorer appear to work as it would work in Firefox, Opera etc... As of 17th June 2010, it is confirmed to work in Internet Explorer versions 6, 7 and 8. This plugin adds three additional elements to the DOM; a <span> element that acts as the select container; an <a> element that acts as an overlay; and another <span> element within the <a> element that adds the visual part. Class names representing the browser version and which state the select is in are added to the container and the the overlay. For Internet Explorer 6, you should also use the bgiframe plugin. View the page source to see how to use this jQuery plugin. Contact me here with any queries or bug reports etc.

CSS Specificity Some people are confused by CSS Specificity, especially with all of the (not-so) new CSS3 Selectors. The image below may help make sense of CSS Specificity. Download the PDF Legend: X-0-0: The number of ID selectors, represented by Sharks0-Y-0: The number of class selectors, attributes selectors, and pseudo-classes, represented by Fish 0-0-Z: The number of type selectors and pseudo-elements, represented by Plankton a la Spongebob*: The universal selector has no value +, >, ~: combinators, although they allow for more specific targeting of elements, they do not increase specificity values:not(x): The negation selector has no value, but the argument passed increases specificity CSS SpeciFISHity You can download the PDF of fishy CSS specificity here Specificity determines which CSS property declaration is applied when two or more declarations apply to the same element with competing property declarations. With CSS3 Selectors, order is even more important, as is understanding specificity: !

Related: