You are not logged in.
You are right, my locale.conf got screwed up. I had LOCALE instead of LANG.
Thanks!
Offline
Hi, I'm new. I'm trying to print the icons in xterm and then to the statusbar, i get only a rectangle. The font is recognized , because I'm using it, but not the icons.
I've tried this and the output was a little rectangle.
echo -e "\x84"
And this is my .Xresource:
! Xft settings ---------------------------------------------------------------
Xft.dpi: 96
Xft.antialias: true
Xft.rgba: rgb
Xft.hinting: true
Xft.hintstyle: hintslight
*faceName: ohsnap.icons
*faceSize: 14
*dynamicColors: true
*foreground: #D7D0C7
*background: #151515
!black
! *color0: #AF875F
! *color8: #AF875F
*color0: #101010
*color8: #404040
!red
*color1: #E84F4F
*color9: #D23D3D
!green
*color2: #B8D68C
*color10: #A0CF5D
!yellow
*color3: #E1AA5D
*color11: #F39D21
!blue
*color4: #7DC1CF
*color12: #4E9FB1
!magenta
*color5: #9B64FB
*color13: #8542FF
!cyan
*color6: #6D878D
*color14: #42717B
!white
*color7: #dddddd
*color15: #dddddd
*borderColor: #151515
*colorBD: #ffffff
*cursorColor: #ff8939
*cursorColor2: #151515
Can someone show me the error?
Last edited by etere (2012-12-30 15:07:32)
Offline
Howdy. I don't know if it will make a difference but maybe try using
xterm*font: -*-ohsnap.icons-medium-r-*-*-14-*-*-*-*-*-*-*
xterm*boldFont: -*-ohsnap.icons-bold-r-*-*-14-*-*-*-*-*-*-*
You can try pasting the rectangle into your script and see if that works or possibly try using another terminal like rxvt-unicode (urxvt) and see if it still happens. Or maybe check your locale settings.
Last edited by stlarch (2012-12-31 16:04:24)
Offline
Howdy. I don't know if it will make a difference but maybe try using
xterm*font: -*-ohsnap.icons-medium-r-*-*-14-*-*-*-*-*-*-* xterm*boldFont: -*-ohsnap.icons-bold-r-*-*-14-*-*-*-*-*-*-*
You can try pasting the rectangle into your script and see if that works or possibly try using another terminal like rxvt-unicode (urxvt) and see if it still happens. Or maybe check your locale settings.
Thanks! I didnt know that I have to set my locale to ISO88591. Now it works!
Happy new year!
Offline
While using ohsnap in urxvt and doing printf '\xXY' , none of the icons past C1 won't print in the terminal and can't be used in the lemon bar. Any reason for this behaviour?
Offline
@theGunslinger, I haven't made any changes in a while, so if they were working before, I would guess it's something on your end. A common problem seems to be with locale settings. I would check that first. Is anyone else having problems?
Offline
ohsnap is awesome! i'm wondering if you can add 15px and 16px. i want them for my i3status bar, 14px looks small in my screen.
thanks
Offline
@OBLiQUE , here's a 15 that I made a while back you can try http://ompldr.org/vaTgwZw/ohsnap15.tar.gz
you'll have to install it manually
Offline
Anybody could help ?
open the gbdfed browse the ohsnap icon from xfonts , step page 2 and i chose the icon , the belows two characters (like 80, 89, 8A, AD , B8 etc ) how to print and view correctly?
Offline
@F34R, you can do something like
echo -e '\xC9'
for example and then copy the output to a script.
Offline
I've read some of the post, even in other 3ds, but I cannot figure out the solution.
Problems:
1) Encoding set to UTF-8
I can get symbols if I run from the terminal # urxvt -fn "i put here ohsnap font" --> this works, symbols are shown.
The script is not working
2) Encoding set to ISO-8859-1
I cannot get the Powerline Symbols in the terminal, but I do get the symbols in the status bar
I've set LANG and the other LC_*, also LC_ALL to "en_US.UTF-8" as in this way I can get the font for the Powerline correctly in URxvt. And this is fine. It works.
termName is set to urxvt-256-color.
Then, I wanted to use also you Ohsnap for the icons in my DWM status bar, but they are not displayed in my script.
Even if I simply do something like:
while true; do
xsetroot -name "\xB5"
sleep 2
done
I get no flash symbol, as in this link: http://ompldr.org/vYm5vNQ
I think I can use a different locale for a script, but saying at the start of the script
LANG="en_US.ISO-8859-1"
or even setting LC_ALL, which should override everything, has no effect, and maybe it's not so right to do that...I don't know.
I can see the symbol only if I set in my .zshrc LC_* and LANG to "en_US.ISO-8859-1".
How can I solve this?
If I simply run urxvt like: LANG="en_US.UTF-8" from the terminal, having set encoding to en_US.ISO-8859-1 it's fine, but how can I've tried in the .xinitrc file and it does not work.
i.e.:
LANG="en_US.UTF-8" urxvtd -q -o -f
What am I missing?
Last edited by mattmusc (2013-05-15 14:57:02)
Make everything as simple as possible but not simpler--A. Einstein
Offline
I have been trying to use this font for my infobar. The font itself is working with no issues, but I can't get the icons to work. My infobar is bar.
This is my config.h:
/* The height of the bar (in pixels) */
#define BAR_HEIGHT 18
/* The width of the bar. Set to -1 to fit screen */
#define BAR_WIDTH -1
/* Offset from the left. Set to 0 to have no effect */
#define BAR_OFFSET 0
/* Choose between an underline or an overline */
#define BAR_UNDERLINE 1
/* The thickness of the underline (in pixels). Set to 0 to disable. */
#define BAR_UNDERLINE_HEIGHT 1
/* Default bar position, overwritten by '-b' switch */
#define BAR_BOTTOM 0
/* The fonts used for the bar, comma separated. Only the first 2 will be used. */
#define BAR_FONT "-*-ohsnap.icons-*-*-*-*-11-*-*-*-*-*-*-*","fixed"
/* Some fonts don't set the right width for some chars, pheex it */
#define BAR_FONT_FALLBACK_WIDTH 6
/* Color palette */
#define COLOR0 0x272727 /* background */
#define COLOR1 0xd0cecb /* foreground */
#define COLOR2 0xe9f2ac /* yellow */
#define COLOR3 0xd75f5f /* light dark red*/
#define COLOR4 0x080808 /* black */
#define COLOR5 0xffaf5f /* light orange*/
#define COLOR6 0x87afd7 /* light blue*/
#define COLOR7 0x8787af /* light red */
#define COLOR8 0x5f8787 /* A la blalig gra*/
#define COLOR9 0x808080 /* grey */
The script(test.sh) I am testing this with is:
#!/usr/bin/bash
clock=$(date "+%a %b %d, %k:%m")
echo -e "\xc9 $clock"
and the icon does not show up when I pipe it into bar with the command
Any ideas what I might be doing wrong?
Last edited by aparthia (2013-06-12 09:47:25)
Offline
@aparthia, try doing
echo -e '\xc9'
and then paste the output (the symbol) into your script instead and see if that works.
@mattmusc, I don't think the urxvt in the repos will work. OK100 had one in the aur that worked but it doesn't appear that he maintains it anymore. I think he compiled it with --enable-unicode3 flag.
Last edited by stlarch (2013-06-14 03:54:22)
Offline
How would I go about finding out which special character represents which icon?
ie. "Ñ" = cpu icon, "Î" = memory icon, etc.
Love the font btw
EDIT: Solution: You can open up another terminal with the ohsnap font
urxvt -fn -*-ohsnap.icon-medium-r-*-*-14-*-*-*-*-*-*-*
and run a shell script which prints out all the glyphs
for i in {50..255}; do printf "\\$(printf '%03o' $i)\n" ; done
Then you can copy paste them, or run the same script inside another terminal with the normal fonts and map the glyphs
https://bbs.archlinux.org/viewtopic.php … 1#p1292871
Last edited by Winston-Wolfe (2013-06-27 13:38:16)
Offline
Can anyone help me with this?
config.h
static const char font[] = "-*-ohsnap.icons-medium-r-normal-*-11-*-*-*-*-*-*-*";
static const char *tags[] = { "chat", "dev", "media", "www \xc9" };
No icon will show up, but the font is infact being used :
It's like only the icons wont load. I have tried to implement them into conky also, didnt work.
When I set urxvt's font to use it and I :
echo -e "\xc9"
it will print the icon.
The font shows up in xfontsel. why arent the icons loading??
Also, why isnt the font an option for me to use on my other terminals, like lxterminal, or tilda?
I have the font folder added to my xorg.conf, and my xinitrc loads it aswell.
Last edited by invisiblemannnn (2013-06-27 13:17:59)
Offline
Did you not read the post before yours?
dwm won't interpret the codes for the glyph you have to print it out in a terminal and copy it to config.h .
You're just jealous because the voices only talk to me.
Offline
When I try to print the glyph in my terminal, it only shows a ? inside a diamond.
It will only display if I run urxvt -fn -*-ohsnap.icons-*-* blah blah and then print it.
Anyone know what I'm doing wrong?
pic related:
http://i.imgur.com/CmhBML9.png
Last edited by invisibleman__ (2013-08-19 18:16:34)
Offline
When I try to print the glyph in my terminal, it only shows a ? inside a diamond.
It will only display if I run urxvt -fn -*-ohsnap.icons-*-* blah blah and then print it.
Anyone know what I'm doing wrong?
pic related:
http://i.imgur.com/CmhBML9.png
Technically you aren't doing anything wrong, it's just that you don't quite have an understanding of what's going on. There's a section available to font makers that doesn't always get used and Grandpa Dave used that free space to add some icons to a font(an excellent idea and well done too). The font you use regularly in urxvt has nothing in that space to show you when you make a call there so urxvt has a ? in a diamond as a default for that. Copying that ? in a diamond to a config that will use ohsnap-icons should have the correct glyph shown. It's a matter of trust and having a go. The worst that can happen is you'll need to re-edit a config file and have a quick rebuild.
This is where using a second DISPLAY or Xephyr to check your edits can help when you are configuring a lightweight wm.
You're just jealous because the voices only talk to me.
Offline
I have to be, cause look at my config :
http://i.imgur.com/QmdrDaw.png
And this is what happens :
http://i.imgur.com/6tddJe7.png
Offline
No icon for ethernet connection? I can only seen a lot wifi icons.
Offline
Can someone give me the symbols for muted sound please?
Edit: NM, I've found it. It's 'ë' or echo -e '\xEB'
Last edited by 0wl (2013-10-16 01:35:28)
Offline
Can anybody help me figure out what I am doing wrong?
I can seem to get these glyphs working in my DWM or conky.
I am using conky-cli, and here is my config :
background no
out_to_console yes
total_run_times 0
update_interval 5
use_spacer none
use_xft yes
xftfont ohsnap.cions:pixelsize=11
TEXT
Ñ ${cpu}% | Î ${memperc}% | ñ ${battery_percent}% | ª ${acpitemp} | í ${exec amixer get Master -M | grep -oE "[[:digit:]]*%"} | É ${time %I:%M} | ¤ ${addr wlan0}
The entire conky doesnt even show up in my dwm bar. I have :
sleep 3 && conky | while read -r; do xsetroot -name "$REPLY"; done &
in my .xinitrc
I am using dwm, here i my config.h
/* See LICENSE file for copyright and license details. */
/* appearance */
static const char font[] = "-*-ohsnap.icons-medium-r-*-*-11-*-*-*-*-*-*-*";
static const char normbordercolor[] = "#000000";
static const char normbgcolor[] = "#000000";
static const char normfgcolor[] = "#FFFFFF";
static const char selbordercolor[] = "#000000";
static const char selbgcolor[] = "#000000";
static const char selfgcolor[] = "#206167";
static const unsigned int borderpx = 3;
static const unsigned int snap = 32;
static const Bool showbar = True;
static const Bool topbar = True;
static const unsigned int systrayspacing = 2; /* systray spacing */
static const Bool showsystray = True; /* False means no systray */
/* tagging */
static const char *tags[] = { "©", "¹", "¨", "Ï" };
/* rules */
static const Rule rules[] = {
/* class instance title tags mask isfloating monitor */
{ "Firefox", NULL, NULL, 1 << 2, False, -1 },
{ "Pidgin", NULL, NULL, 1 << 0, False, -1 },
{ "Skype", NULL, NULL, 1 << 0, False, -1 },
};
/* layout(s) */
static const float mfact = 0.55; /* factor of master area size [0.05..0.95] */
static const int nmaster = 1; /* number of clients in master area */
static const Bool resizehints = False; /* True means respect size hints in tiled resizals */
static const Layout layouts[] = {
/* symbol arrange function */
{ "þ", tile }, /* first entry is default */
{ "ý", NULL }, /* no layout function means floating behavior */
{ "ÿ", monocle },
};
/* key definitions */
#define MODKEY Mod4Mask
#define TAGKEYS(KEY,TAG) \
{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \
{ MODKEY|ControlMask, KEY, toggleview, {.ui = 1 << TAG} }, \
{ MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \
{ MODKEY|ControlMask|ShiftMask, KEY, toggletag, {.ui = 1 << TAG} },
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
/* commands */
static const char *dmenucmd[] = { "dmenu_run", "-fn", font, "-nb", normbgcolor, "-nf", normfgcolor, "-sb", selbgcolor, "-sf", selfgcolor, NULL };
static const char *gyazocmd[] = { "gyazo", NULL };
static const char *mocpnext[] = { "mocp", "--next", NULL };
static const char *mocpprev[] = { "mocp", "--previous", NULL };
static const char *mocppause[] = { "mocp", "--toggle-pause", NULL };
static const char *mutecmd[] = { "amixer", "sset", "Master", "toggle", NULL };
static const char *termcmd[] = { "xterm", NULL };
static const char *volup[] = { "amixer", "set", "Master", "5%+", NULL };
static const char *voldown[] = { "amixer", "set", "Master", "5%-", NULL };
static Key keys[] = {
/* modifier key function argument */
{ MODKEY, XK_r, spawn, {.v = dmenucmd } },
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
{ MODKEY, XK_Up, spawn, {.v = volup } },
{ MODKEY, XK_Down, spawn, {.v = voldown } },
{ MODKEY, XK_Left, spawn, {.v = mocpprev } },
{ MODKEY, XK_Right, spawn, {.v = mocpnext } },
{ MODKEY, XK_p, spawn, {.v = mocppause } },
{ MODKEY, XK_m, spawn, {.v = mutecmd } },
{ MODKEY, XK_s, spawn, {.v = gyazocmd } },
{ MODKEY, XK_h, togglebar, {0} },
{ MODKEY|ControlMask, XK_Up, incnmaster, {.i = +1 } },
{ MODKEY|ControlMask, XK_Down, incnmaster, {.i = -1 } },
{ MODKEY|ControlMask, XK_Left, setmfact, {.f = -0.05} },
{ MODKEY|ControlMask, XK_Right, setmfact, {.f = +0.05} },
{ MODKEY, XK_k, killclient, {0} },
{ MODKEY, XK_space, setlayout, {0} },
TAGKEYS( XK_1, 0)
TAGKEYS( XK_2, 1)
TAGKEYS( XK_3, 2)
TAGKEYS( XK_4, 3)
TAGKEYS( XK_5, 4)
TAGKEYS( XK_6, 5)
TAGKEYS( XK_7, 6)
TAGKEYS( XK_8, 7)
TAGKEYS( XK_9, 8)
{ MODKEY, XK_q, quit, {0} },
};
/* button definitions */
/* click can be ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */
static Button buttons[] = {
/* click event mask button function argument */
{ ClkLtSymbol, 0, Button1, setlayout, {0} },
{ ClkClientWin, MODKEY, Button1, movemouse, {0} },
{ ClkClientWin, MODKEY, Button3, resizemouse, {0} },
{ ClkTagBar, 0, Button1, view, {0} },
{ ClkTagBar, 0, Button3, toggleview, {0} },
};
I have created 20-fonts.conf inside of my /etc/X11/xorg.conf.d/ directory and i put the fontpath /usr/share/fonts/local
The problem is, regular text works find but if i set the config to use a glyph charcter it doesnt show up. The font itself is working, just no glyphs.
Is this a locale issue maybe?
Last edited by djangorango (2014-01-20 00:09:42)
Offline
djangorango it looks like you misspelled ohsnap.icons
xftfont ohsnap.cions:pixelsize=11
You're just jealous because the voices only talk to me.
Offline
djangorango it looks like you misspelled ohsnap.icons
xftfont ohsnap.cions:pixelsize=11
yeah i fixed that, that didnt do anything. its not a conky issue, or even dwm.
I think it is because I dont use an xorg conf file maybe, not sure. maybe a locale issue too.
this has just been a persistsing issue and not one can help me with it
Offline
@djangorango, try this
use_xft no
font -*-ohsnap.icons-medium-r-normal-*-11-*-*-*-*-*-*-*
Offline