convert font path from system to imported

Home Forums General News and releases convert font path from system to imported

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #25817
    msepsis
    Participant
      • Topics: 219
      • Replies: 732
      • Total: 951
      • ★★★

      I was trying to find in the xml for the panel any small difference that determines whether the font is embedded via imported resource or if the font is a system font.
      I could not find any difference in the XML – Any tips here to update a panel to using the fonts as imported resources as opposed to installed fonts to the system?
      Instead of bundling the font with the exported instance I just want to import the ttf to my bpanelz, then do search and replace to the XML to update where the program is looking for the font – strange that I dont see any difference in the path when doing a basic test panel with 2 labels – both using the same font, but one is using a ttf imported as a resource, the other is using the font installed to the system.

      Monstrum Media | Music, Sound & Software Design, Chicago / San Francisco listen

      #25889
      msepsis
      Participant
        • Topics: 219
        • Replies: 732
        • Total: 951
        • ★★★

        I did a quick test, it’s kinda weird but in the end it seems
        uiLabelFont=”fontName;14;0;0;0;0;1;0″ = using system font “fontName”
        uiLabelFont=”fontName;14;0;0;0;0;1;1″ = using imported font “fontName”

        It’s weird – at least on a mac if you have the font installed on your system, then you import it as a resource to a panel – it seems even if you select the font from the “Imported Fonts” section of the font list, when you go check again it will have been reset to the installed instance of that font. I found that you literally have to remove the font from your system in order to properly select an imported instance font otherwise the reference to the imported instance gets reset.

        Monstrum Media | Music, Sound & Software Design, Chicago / San Francisco listen

        #25896
        atom
        Keymaster
          • Topics: 159
          • Replies: 2945
          • Total: 3104
          • ★★★★★

          I have to check that, the font subsystem on the mac is different then on windows (where i did most of the font stuff tests), i thought that JUCE would cover all that up, but it might be a problem.

          #25899
          atom
          Keymaster
            • Topics: 159
            • Replies: 2945
            • Total: 3104
            • ★★★★★

            I also found that when converting a Font() to a String() (serializing it) i first looked at the OS font set and if the font name matched that was used, so it might be a problem (if a font name exists on 2 lists OS and Imported the OS was chosen first), i changed that so that the Imported list is searched first.

            #25902
            atom
            Keymaster
              • Topics: 159
              • Replies: 2945
              • Total: 3104
              • ★★★★★

              Oh yeah and a way to make sure that your font will always be taken from the Imported table is to name it in some distinct way, add a prefix to the file or something.

            Viewing 5 posts - 1 through 5 (of 5 total)
            • The forum ‘News and releases’ is closed to new topics and replies.
            There is currently 0 users and 106 guests online
            No users are currently active
            Forum Statistics
            Threads: 2,495, Posts: 17,374, Members: 77,605
            Most users ever online was 12 on January 22, 2019 3:47 pm
            Ctrlr