fluxbox toolbar: howto set "icon" for a button, vs ascii labeltext

Forum Forums General Tips and Tricks fluxbox toolbar: howto set "icon" for a button, vs ascii labeltext

  • This topic has 2 replies, 2 voices, and was last updated Jan 16-2:26 pm by Anonymous.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #16232
    Anonymous

      FYI: unicode glyph character(s) can be used instead of traditional text for button labels

      .

      In the screenshot, an “updown arrows symbol” is displayed for the “(Toggle) Show Desktop” button.
      For my “meld popper” button, I just named it “meld” as a heuristic. Button name can be whatever you wish.
      The primary benefit of using a glyph instead of spelled-out-labeltext (IMO) is conservation of space.

      In case none of the glyphs provided by the pre-installed fonts suits your fancy,
      you can find 169 “icon” fontsets available for download here: 169 “icon” fontsets Also, 228 “shapes” fontsets NOTE: not all of these fontsets provide a “ttf” format ~~ just .odf(?) or other format. Skimming debian packages archive, I found a package “fonttools” which reputedly contains a program enabling conversion from one format to another… but the details of “all this font stuff” is outa my league.

      here are some debian packages providing ability to browse ttf fonts:
      font-manager, gucharmap, gnome-characters

      For the screenshot, I used the “gnome-characters” program.
      Might be a quirk of my local system, but MANY of the characters I attempted to browse across various fontsets wind up being displayed as “tofu” (rectangle and numbers). Anyhow, via trial and error I’ve learned that if a character is correctly displayed within geany when pasted to my ~/.fluxbox/init file, it will also display correctly in the toolbar. Maybe (i didn’t spend much time testing) typing U+035 or U\0035 or similar, could be used instead of pasting to get a correct result.

      ps:
      topic title mentions fluxbox. The same (use of glyphs) may also work for labeltext(s) in other WMs.

      #16428
      Member
      PPC
        Helpful
        Up
        0
        ::

        Hi, Skidoo.
        It’s nice that you made this tip public 🙂
        Related to toolbar labels, and also to fluxbox personalization, I made a post over at https://forum.mxlinux.org/viewtopic.php?f=40&t=47962&sid=5def78821c60441ca1328da1ed596013
        I addressed, on the end of my B and C topics, a “problem” I have on Fluxbox. I’m not able to change fonts in the Fluxbox entries related to the buttons I created… Is it just me? Am I doing something wrong (for example- editing the font you use on the default home button, changing it’s size, bold, nothing works)?
        The way I understand the mechanics of the init configurarion file, if you set a font and then in the label you use a character from that font, geany should display it as the character corresponding to it in the font geany uses, not directly the glyph you want to use on the label (handy for using fonts like the one you refered to that only display glyphs, not regular characters, but also applies to fonts that can be usefull to use as labels in the buttons, like the font “Dingbats”…

        Thanks in advance,
        P

        #16458
        Anonymous
          Helpful
          Up
          0
          ::

          PPC, possibly you’re attempting to change font of Menu button to a size larger than the toolbar.height constraint specified in your init or your style (aka theme) can accommodate. If your toolbar.height is tiny (offhand, from memory, I’m guessing mine is 16px) maybe fluxbox tries to apply the font, but performs fallback because the fontset lacks a suitably-sized set of glyphs. I don’t know, are ttf fonts “scalable”?

          Yes, with my tiny toolbar.height, I’ve noticed several fontfaces can’t be used. I’m guessing they don’t have a 14pt(?) or whatever variant that can be rendered into the constrained space.

          Also, a detail I omitted from the original post:
          I tried a few (4?) COLOR fontfaces that I found at the site linked in post#1 and found that none of ’em yielded a properly rendered glyph when I attempted to assign them as a button.font ~~ broken glyph (no color, no b/w fallback). Mentioning this because it’s another “is it just me?” potential issue someone may stumble across.
          ^— Edit: hmmm, IIRC, not “broken” but outright invisible, not displayed

          I should know, but can’t recall, whether fluxbox is capable of rendering any antialiased font formats other than ttf. For anyone interested in being a trailblazer, that’s another line of experimentation we might collectively test, and document. Heh, maybe it’s already mentioned in the manpage?

          apropos fluxbox
          man fluxbox-style
          I found a broken link (well, not broken but outdated, it redirects to http://xfree86.org/4.3.0/fonts2.html) and briefly searched within the page for “alias” (anti-aliased fonts) and “ttf”… and my eyes quickly glossed over. ttf type1 and type2 and CIDF and blahblah. Unapologetically, I’m just really disinterested in the prospect of learning the nitty-gritty details of fonts.

        Viewing 3 posts - 1 through 3 (of 3 total)
        • You must be logged in to reply to this topic.