Example #1
0
def get_font_list():
    '''Get a list of all the fonts available on this system.
    '''
    CoreLabel._fonts_dirs.append(FONTS_DIR)
    fonts_path = CoreLabel.get_system_fonts_dir()
    flist = []
    resource_add_path(FONTS_DIR)
    for fdir in fonts_path:
        for fpath in sorted(os.listdir(fdir)):
            if fpath.endswith('.ttf'):
                flist.append(fpath[:-4])
    return sorted(flist)
Example #2
0
    def get_font_list(self):
        '''Get a list of all the fonts available on this system.
        '''

        fonts_path = CoreLabel.get_system_fonts_dir()
        flist = []

        for fdir in fonts_path:
            for fpath in sorted(os.listdir(fdir)):
                if fpath.endswith('.ttf'):
                    flist.append(fpath[:-4])

        return sorted(flist)
Example #3
0
    def get_font_list(self):
        '''Get a list of all the fonts available on this system.
        '''

        fonts_path = CoreLabel.get_system_fonts_dir()
        flist = []

        for fdir in fonts_path:
            for fpath in sorted(os.listdir(fdir)):
                if fpath.endswith('.ttf'):
                    flist.append(fpath[:-4])

        return sorted(flist)
Example #4
0
    def get_font_list(self):
        """Get a list of all the fonts available on this system."""

        fonts_path = CoreLabel.get_system_fonts_dir()
        flist = []

        for fdir in fonts_path:
            for fpath in sorted(os.listdir(fdir)):
                if not "." in fpath:
                    continue
                font, ext = fpath.rsplit(".")
                if ext == "ttf":
                    flist.append(font)
        return sorted(flist)
Example #5
0
    def get_font_list(self):
        '''Get a list of all the fonts available on this system.
        '''

        fonts_path = CoreLabel.get_system_fonts_dir()
        flist = []

        for fdir in fonts_path:
            for fpath in sorted(os.listdir(fdir)):
                if not '.' in fpath:
                    continue
                font, ext = fpath.rsplit('.')
                if ext == 'ttf':
                    flist.append(font)
        return sorted(flist)
Example #6
0
    def get_font_list(self):
        '''Get a list of all the fonts available on this system.
        '''

        fonts_path = CoreLabel.get_system_fonts_dir()
        flist = []

        for fdir in fonts_path:
            for fpath in sorted(os.listdir(fdir)):
                if not '.' in fpath:
                    continue
                font, ext = fpath.rsplit('.')
                if ext == 'ttf':
                    flist.append(font)
        return sorted(flist)
Example #7
0
class Fonter:
    fonts_paths = CoreLabel.get_system_fonts_dir()
    # fonts_path = fonts_paths[1] + '\\'
    fonts_path = fonts_paths[0]