0

I would like to use a font I have available as a .ttf file for one of my texts.

The obvious way to do that is to install the font system wide and use it that way.

Is there a different path one could take when administrative privileges are not available (the execution of PowerShell scripts is blocked too)? It feels like that should be possible.

edit: I haven't yet gotten the PowerShell method linked here to work. I would like to keep the question up, as I am hoping for a method within Word, to bundle the .ttf with or at least open it for specific documents. (along the lines of: Format -> Fonts -> add Font file to document) edit2: Sadly the execution of PowerShell scripts is unavailable on the machines in question. UnauthorizedAccess

  • 1
    Possible duplicate of [Is it possible to install fonts in Windows without admin rights?](https://superuser.com/questions/1185779/is-it-possible-to-install-fonts-in-windows-without-admin-rights) – fixer1234 Jan 08 '19 at 11:27
  • This question sadly has to be: How do I do that without admin rights and without the PowerShell :( – WordyFonter Jan 08 '19 at 12:09
  • 1
    Possible duplicate of [Using custom fonts without administrator rights?](https://superuser.com/questions/118025/using-custom-fonts-without-administrator-rights) – phuclv Jan 08 '19 at 15:00
  • 1
    Which Windows version are you using? In Windows 10 17704 and above just right click > install. And UnauthorizedAccess doesn't mean that you don't have powershell. You just need to run [`set-executionpolicy remotesigned`](https://superuser.com/q/106360/241386) to allow script execution, or if it's not possible just copy all the lines in the script and paste directly onto Powershell, since you always have rights to execute commands – phuclv Jan 08 '19 at 15:04

1 Answers1

0

You can't install a font permanently under a non-admin account, but you can do it temporarily (for the current session). Check Pabru's answer here.

P.S. OK, if PowerShell doesn't work, this is the corresponding MSVC code:

int _tmain(int argc, TCHAR* argv[]) {
    if(argc != 2)   {
        std::cout << "Usage: RegFont <font-file>\n";
        return 1;
    }

    AddFontResource(argv[1]);
    return 0;
}

Try running RegFont32 <font-file> or RegFont64 <font-file>

phuclv
  • 26,555
  • 15
  • 113
  • 235
rg_software
  • 166
  • 4