[apple] os x에서 쉘 명령이있는 (활성화 된) 글꼴 목록

활성화 된 글꼴 목록을 얻기위한 쉘 명령이 있습니까? 다음과 같은 것 :

 some_font_util -activated -format 'file: name'

다음과 같은 형식으로 활성화 된 글꼴 목록을 가져옵니다.

/Library/Fonts/CourNI.ttf: Courier New Italic

… 또는 비슷한 것이 있습니까?

저는 Lion을 사용하고 있습니다. MacPorts 또는 AppleScript ( osascript명령 으로 실행)의 어떤 것도 환영합니다.



답변

나는 이것이 꽤 오래된 게시물이라는 것을 알고 있지만, 비슷한 것을 찾는 동안 Google에서 우연히 발견했습니다 (대부분 터미널을 통해 활성 글꼴을 나열하려고합니다). 활성화 된 글꼴이 시스템 정보에 나열되어 있음을 기억했습니다. system_profiler 명령에서 가져옵니다. system_profiler에서 글꼴 정보를 가져 오는 명령이 있습니다.

system_profiler SPFontsDataType

그게 다야. 다음과 같은 형식으로 거대한 글꼴 데이터 목록을 반환해야합니다.

Fonts:

Arial Narrow.ttf:

  Kind: TrueType
  Valid: Yes
  Enabled: Yes
  Location: /Library/Fonts/Arial Narrow.ttf
  Typefaces:
    ArialNarrow:
      Full Name: Arial Narrow
      Family: Arial Narrow
      Style: Regular
      Version: Version 2.38.1x
      Vendor: The Monotype Corporation
      Unique Name: Arial Narrow Regular : 2007
      Designer: Robin Nicholas, Patricia Saunders
      Copyright: © 2007 The Monotype Corporation. All Rights Reserved.
      Trademark: Arial is a trademark of The Monotype Corporation in the United States and/or other countries.
      Description: Monotype Drawing Office 1982. A contemporary sans serif design, Arial contains more humanist characteristics than many of its predecessors and as such is more in tune with the mood of the last decades of the twentieth century. The overall treatment of curves is softer and fuller than in most industrial-style sans serif faces. Terminal strokes are cut on the diagonal which helps to give the face a less mechanical appearance. Arial is an extremely versatile family of typefaces which can be used with equal success for text setting in reports, presentations, magazines etc, and for display use in newspapers, advertising and promotions.
      Outline: Yes
      Valid: Yes
      Enabled: Yes
      Duplicate: No
      Copy Protected: No
      Embeddable: Yes

원하는대로 grep하고 조작 할 수 있어야합니다.


답변

$ fc-list : file family |grep \/Library

grepping / Library는 / usr / X11 *에서 X11에서만 사용되는 많은 글꼴을 필터링합니다. 귀하의 예를 고려할 때, OS X 고유의 것을 선호한다고 가정합니다. 이 가정에서 내가 틀렸다면, 가족 후에 모든 것을 꺼내십시오.

이 명령은 많은 행을 자체적으로 반환합니다. 여기에서 내가 본 몇 가지 흥미로운 명령이 있습니다.

/System/Library/Fonts/AppleGothic.ttf : AppleGothic
/ Library / Fonts / Apple LiGothic Medium.ttf : Apple LiGothic
/ System / Library / Fonts / Apple Braille Pinpoint 8 Dot.ttf : Apple Braille
/ System / Library / Fonts / Apple 점자 개요 6 Dot.ttf : Apple Braille
/ System / Library / Fonts / Apple Symbols.ttf : Apple Symbols
/ System / Library / Fonts / Apple Braille Pinpoint 6 Dot.ttf : Apple Braille
/ System / Library / Fonts / Apple Braille. ttf : Apple Braille
/Library/Fonts/AppleMyungjo.ttf : AppleMyungjo
/ System / Library / Fonts / Apple Braille Outline 8 Dot.ttf : Apple Braille
/ Library / Fonts / Apple LiSung Light.ttf : Apple LiSung
/ Library / Fonts / Apple Chancery.ttf : Apple Chancery
/ System / Library / Fonts / Apple Color Emoji.ttf : Apple Color Emoji, Apple 彩色 表情> 符號, Apple farve-emoji, Apple Farben-Emoji, Applen väri-emoji, Apple Emoji couleur, 컬러 이모 지 애플, 애플 카라라 絵 文字, Apple 컬러 이모티콘, Apple Kleur-Emoji, Apple farge-emoji, Apple Emoji em Cores, Цветные эмодзи Apple, Apple färg-emoji, Apple 彩色 表情 符号, لون, Apple Emoji color
/ Library / Fonts / Comic Sans MS.ttf : 만화 Sans MS
/ Library / Fonts / Microsoft / MS Gothic.ttf : MS Gothic, MS ゴ シ ッ ク
/ Library / Fonts / Microsoft / Stencil : 스텐실
/ Library / Fonts / Microsoft / Verdana : Verdana
/ Library / Fonts / Microsoft / Georgia : Georgia
/ 라이브러리 / 글꼴 / Microsoft / 오닉스 : 오닉스


답변