fontdirs_windows.go 410 B

123456789101112131415161718
  1. // Copyright 2016 Florian Pigorsch. All rights reserved.
  2. //
  3. // Use of this source code is governed by a MIT-style
  4. // license that can be found in the LICENSE file.
  5. package findfont
  6. import (
  7. "os"
  8. "path/filepath"
  9. )
  10. func getFontDirectories() (paths []string) {
  11. return []string{
  12. filepath.Join(os.Getenv("windir"), "Fonts"),
  13. filepath.Join(os.Getenv("localappdata"), "Microsoft", "Windows", "Fonts"),
  14. }
  15. }