Is it possible to use custom fonts with github's markdown? I'm currently loading an image as a logo, yet rendering a font would be faster and nicer.
rendering a font would be faster and nicer.
Yes, except you wound not use any (multiple) colors in said "icon as a font".
See "GitHub redesigns its icons using a custom font"
You can, of course, take a monotone font-rendered icon and set its colour to, for example, red or blue, but that changes the entire icon; you can’t have different parts of the icon use different colours, or use shading
(example of CSS effects for Icon Font here, from the Trello article)
But, as far as I can see (Markdown Cheatsheet, and Markdown Help), no, you cannot have a custom font.
You can have a custom font, just generate it with https://github.com/crocodilejs/custom-fonts-in-emails and then you can just put the image/upload it to GitHub readme.
Related
I'm trying to build a map which allows users to choose icons for their geojson points. I just want to use the default map styles (streets|outdoors|light|dark|satellite) and Maki icons, however, not all icons are showing on all styles.
For example 'bicycle' and 'cafe' show on all the map styles, 'circle' only shows on satellite, and 'marker' doesn't show on any of them.
On a style I developed for another purpose, all markers show fine even though I know I didn't do anything special to 'add' them to the style.
So, my code is not the problem, my question is about the availability of maki icons on the default styles. I would have thought they'd all be available on all styles, but it seems not.
How can I tell which icons will work across all the default styles (short of trial and error)?
Is there some way I can 'enable' all the icons on a style?
Failing that, if I do have to make my own versions of the basic styles, I guess I can, but how do I ensure all the icons are loaded into the style?
The standard Mapbox styles are fairly optimised, and don't include anything that's not needed to display them. So, icons that aren't used in the style itself aren't included.
When you create a new style, I think Mapbox by default includes the whole Maki set.
If you can modify the style file (JSON) directly, you could try changing this line (for the Mapbox Streets style):
"sprite": "mapbox://sprites/mapbox/streets-v9",
to the equivalent in one of your custom styles, something like:
sprite": "mapbox://sprites/woowoowoo/htd32t6hd236t",
But it might cause problems if there are icons in Mapbox Streets that aren't in your style.
In short, I don't think there's a simple way to add "all the icons". Each style has its own set of icons.
A better way might be to use addImage/loadImage to load the custom icons you want, at run time. See this example.
Im using jstree with a dark background, so I wonder how can I change the color of dash-lines(not sure if I call it correctly) between each node. Is it possible with CSS?
As I checked, it seems the dash-lines coming from 32px.png file.
BR
Nima
You will have to edit the 32px.png file to change the dotted line color. I did this for my dark-background web page and it looks much better. I edited the png file with Photoshop Elements and used the "Enhance| Adjust Color| Replace Color" menu to change the black color to a lighter grey by moving the Lightness slider. I also changed the interior color of the selected arrows. Once done editing, save a copy of the original and then replace the file in your CSS themes folder where style.css is.
I can't attach my copy of 32px.png, but here's how to make the change in Photoshop Elements. Other photo editors likely have the same functionality.
Replace Color in Photoshop Elements – Instructions
You can use Bootstrap themed JSTree.
Check out link: enter link description here
with CSS is not posible.
In the official documentation they suggested to use css for localizing the tool tips of vaadin richtext area and it says:
Localizing RichTextArea Toolbars
The rich text area is one of the few components in Vaadin that contain
textual labels. The selection boxes in the toolbar are in English and
currently can not be localized in any other way than by inheriting or
reimplementing the client-side VRichTextToolbar widget. The buttons
can be localized simply with CSS by downloading a copy of the toolbar
background image, editing it, and replacing the default toolbar. The
toolbar is a single image file from which the individual button icons
are picked, so the order of the icons is different from the rendered.
The image file depends on the client-side implementation of the
toolbar.
.v-richtextarea-richtextexample .gwt-ToggleButton
.gwt-Image {
background-image: url(img/richtextarea-toolbar-fi.png)
!important;
}
I've downloaded the toolbar background image.
My question is how can I localize the string used for the tool-tips of the Rich Text Area tool bar? Or is there any vaadin add-ons that can be used as a replacement of Rich Text Area with language localization feature?
Try Vaadin Addon - Wrapper for CK Editor.
Here you can find online demo. It automaticaly localizes to my browser language.
You can find more information on official CKEditor site.
I need to add my own images into GTK Icon Theme, so i need to somehow figure the size in pixels GTK uses to display icons of different predefined sizes: GTK_ICON_SIZE_BUTTON, GTK_ICON_SIZE_MENU, GTK_ICON_SIZE_DIALOG etc. GTK manual states that sizes are available as value of gtk-icon-sizes property of GtkSettings object. I have executed following code on latest ubuntu:
#!/usr/bin/env python
import gtk; print(gtk.settings_get_default().get_property('gtk-icon-sizes'))
But the output is very short:
'panel-menu=22,22;gtk-button=16,16'
Where can i find rest of the sizes, for example for GTK_ICON_SIZE_DIALOG or GTK_ICON_SIZE_LARGE_TOOLBAR?
GTK resizes the icons to whatever size they need to be. According to the Icon Theme Specification, you should make at least one 48x48 icon, and optionally a scalable SVG icon. That is enough to be able to display any of those sizes.
The Tango Icon Theme Guidelines recommend some supplementary sizes that you can make, in order to minimize how often the icon has to be resized internally by GTK.
Just add your images to the icon list with gtk_icon_theme_add_builtin_icon, and then use them as named icons.
An example in Vala:
Gdk.Pixbuf pixbuf;
pixbuf = new Gdk.Pixbuf.from_file_at_size(Path.build_filename(AutovalaPluginConstants.DATADIR,"valaplugin","application.svg"),-1,-1);
Gtk.IconTheme.add_builtin_icon("autovala-plugin-executable",-1,pixbuf);
I've seen all the talk on the web about the difficulty of using a custom font in iPhone OS. Is it possible, to load a font from within my bundle into the UIWebView component?
EDIT: I saw it in the app called "Omer" by "Rusty Brick"... It seems to be a web view, because I see a delay and during the loading delay the custom area is white. What other component could this have been?
EDIT2: I contacted Rusty Brick. They told me which font it was. A standard font.
It is possible to load custom fonts into your UIWebView in iOS3.2 and above. Add the font to your bundle (see here) then just reference the font in your UIWebView's stylesheet like you would any other font:
<style type='text/css'>font { font-family: DroidSerif; } </style>
It is possible, but you need to make certain to add the Fonts provided by application key-value pair to the Info.plist.
I learned about it in this tutorial: http://tetontech.wordpress.com/2010/09/03/using-custom-fonts-in-your-ios-application/
I tried it with a LWFM and a FFIL font suitcase, but this didn't work. In the end I needed the TTF file of the font.
When referencing the font in your code use the PostScript name. To get the correct name for your font, open the Font Book application, select the font and click on the i in the upper left corner to open the information panel.