font-size

博客CSS样式

╄→尐↘猪︶ㄣ 提交于 2019-12-04 02:34:08
博客园的样式代码: 皮肤是SimpleMemory 页面定制CSS代码如下 /*simplememory*/ #google_ad_c1, #google_ad_c2 {display:none;} .syntaxhighlighter a, .syntaxhighlighter div, .syntaxhighlighter code, .syntaxhighlighter table, .syntaxhighlighter table td, .syntaxhighlighter table tr, .syntaxhighlighter table tbody, .syntaxhighlighter table thead, .syntaxhighlighter table caption, .syntaxhighlighter textarea { font-size: 14px!important; } #home { opacity: 0.80; margin: 0 auto; width: 85%; min-width: 950px; background-color: #fff; padding: 30px; margin-top: 30px; margin-bottom: 50px; box-shadow: 0 2px 6px rgba(100, 100, 100,

移动端适配方案

徘徊边缘 提交于 2019-12-04 02:24:17
原文链接: http://caibaojian.com/mobile-responsive-example.html 固定一个某些宽度,使用一个模式,加上少许的媒体查询方案 使用flexbox解决方案 使用百分比加媒体查询 使用 rem 1. 简单问题简单解决 我觉得有些 web app并一定很复杂,比如拉勾网,你看看它的页面在iphone4,iphone6,ipad下的样子就知道了: 它的页面有一个特点,就是: 顶部与底部的bar不管分辨率怎么变,它的高度和位置都不变 中间每条招聘信息不管分辨率怎么变,招聘公司的图标等信息都位于条目的左边,薪资都位于右边 这种app是一种典型的弹性布局:关键元素高宽和位置都不变,只有容器元素在做伸缩变换。对于这类app,记住一个开发原则就好:文字流式,控件弹性,图片等比缩放。以图描述: 这个规则是一套基本的适配规则,对于这种简单app来说已经足够,同时它也是后面要说的 rem 布局的基础。另外对于拉勾这种app可能需要额外媒介查询对布局进行调整的就是小屏幕设备。举例来说,因为现在很多设计稿是根据iphone6的尺寸来的,而iphon6设备宽的逻辑的像素是375px,而iphone4的逻辑像素是320个像素,所以如果你根据设计稿做出来的东西,在iphone4里面可能显示不下,比如说拉钩网底部那个下载框,你对比看下就知道了,这是4: 这是6: ·

Getting the right font-size on every mobile device

主宰稳场 提交于 2019-12-04 00:22:53
In my mobile app I use kind of big fonts for example: <b style="font-size:100px; font-family:Segoe UI">text</b> When I test it on my phone it looks great but on a smaller phone it's still the same size and it is too big. What css settings should I use to get the same size on every phone? You should be using Media Queries for different device widths. @media only screen and (max-width: 768px) { b { font-size: 20px; } } @media only screen and (max-width: 320px) { b { font-size: 10px; } } And so on... Media queries won't work. Yes you can have varying font size based on the screen size(which is

matplotlib: Controlling pie chart font color, line width

元气小坏坏 提交于 2019-12-03 23:58:30
问题 I'm using some simple matplotlib functions to draw a pie chart: f = figure(...) pie(fracs, explode=explode, ...) However, I couldn't find out how to set a default font color, line color, font size – or pass them to pie(). How is it done? 回答1: Global default colors, line widths, sizes etc, can be adjusted with the rcParams dictionary: import matplotlib matplotlib.rcParams['text.color'] = 'r' matplotlib.rcParams['lines.linewidth'] = 2 A complete list of params can be found here. You could also

Font size. What can I be sure of?

微笑、不失礼 提交于 2019-12-03 23:52:43
What does font size actually mean? Let's take CSS. I have font-size where I can specify a number in pixels , points etc. So, what does 12px mean? And what does 20pt mean? Is it the maximum width of a character, is it the minimum one, is it the max height? Will I know for sure that 5 characters of font-size: 10px will have no more than 50px , no less than that, or exactly that width? Commonly font-size is defined in pixels = px or points = pt Note : 72 pt equals one inch = 2,54 cm The resolution of a screen is defined in px. Obviously, the more pixels on a monitor of equal dimensions the

Vertically align smaller bullets with larger text

北战南征 提交于 2019-12-03 23:00:39
I have a list with bullets. I made the bullets smaller by putting the li text inside a span and making the font-size of the li smaller than that of the span. The problem is that now the bullets are not vertically aligned in relation to the text. How do I fix that? HTML: <ul> <li><span>text1</span></li> <li><span>text2</span></li> <li><span>text3</span></li> <li><span>text4</span></li> </ul> CSS: li{ font-size: 15px; } li span{ font-size: 25px; } jsFiddle: http://jsfiddle.net/tXzcA/ You could just make your own bullet point and make it whatever size you want. li{ font-size: 15px; list-style

why is my truetype font of size 11 rendering different than windows?

安稳与你 提交于 2019-12-03 21:14:18
问题 To wit: Notepad is opened, the font selected as "Arial, Size 11", the words "this is just a test" carefully entered, a screenshot taken: The following Python code is entered and run: import ImageFont, ImageDraw, Image im = Image.open("c:/textimg.png") #the above image pilfont = ImageFont.truetype("arial.ttf", 11) compimg = Image.new("RGB", im.size, (255, 255, 255)) draw = ImageDraw.Draw(compimg) draw.text((0,0), "this is just a test", (0,0,0), font=pilfont) compimg.save("c:/compimg.png") Yet

How to change the default font size in ggplot2

白昼怎懂夜的黑 提交于 2019-12-03 17:53:50
问题 I'd like to know if it is possible to change some default parameters of ggplot2 graphics, like font size for instance, for a whole R session. The idea is to avoid setting them for each plot. 回答1: Use theme_set() theme_set(theme_gray(base_size = 18)) qplot(1:10, 1:10) 回答2: Use theme_set if you want to update for the remainder of your active session: theme_set(theme_grey(base_size = 18)) If you only want to change one graph you can set the base_size in the theme: qplot(1:10, 1:10) + theme_grey

android ProgressDialog fontSize change

夙愿已清 提交于 2019-12-03 16:58:14
Is it possible to change the font size and make text bold which is displayed in a ProgressDialog .I have created a ProgressDialog like this: private ProgressDialog dialog; this.dialog = ProgressDialog.show(Activity.this, "Heading","Message...", true); I want to make Heading bold and increase the font size..pls help If you import android.text.Html; then you will be able to use the Html.fromHtml() method to do it, like so: private ProgressDialog dialog; this.dialog = ProgressDialog.show(Activity.this, Html.fromHtml( "<b>Heading<b>"), Html.fromHtml("<big>Message...</big>"), true); You should also

Best unit for font-sizes in CSS

99封情书 提交于 2019-12-03 16:31:43
问题 What are the advantages & disadvantages of each? em , px , % and pt ? My current choice are percentages, the only reason is because I can globally change the font-size of all elements, just by modifying the font size on the root element (body) 回答1: I would recommend EM — simply because I use Baseline CSS for my basic set up of forms, layout and most importantly type. Can't recommend it enough : http://baselinecss.com/ 回答2: My original design training said em's where possible. I believe a main