OS2 World Community Forum

OS/2, eCS & ArcaOS - Technical => Setup & Installation => Topic started by: warpsalad on October 26, 2017, 10:44:43 am

Title: How to - Install Fonts on OS/2
Post by: warpsalad on October 26, 2017, 10:44:43 am
So I tried installing a font to OS/2 (ArcaOS) by copying it into the main font directory, and while it did copy over--the font viewer still only shows 109 fonts, and I can't use it or view it in the font viewer.

I just want to run this vulnerability discovered in the OS/2 Table to see if it affects IBM's OS/2:
https://bugs.chromium.org/p/project-zero/issues/detail?id=506&redir=1

I've always maintained OS/2 is fairly secure (assuming you're not running insecure software on it), even though it's lacking ASLR and other things--but I am interested in seeing if there are vulnerabilities in the old system after all of these years.
Title: Re: How to - Install Fonts on OS/2
Post by: xynixme on October 26, 2017, 01:54:04 pm
I just want to run this vulnerability discovered in the OS/2 Table to see if it affects IBM's OS/2

</silence>You're still somehow mixing OS/2 and ArcaOS, which are different products. So is eCS. If AO includes INSTFONT.EXE, then execute INSTFONT.EXE for font installation instruction. If you don't have an INSTFONT.EXE (http://hobbes.nmsu.edu/download/pub/os2/util/font/instfont10.zip), then I'd suggest to install it in a PATH directory. Most modern OS/2 font install packages will use it, if available.<silence>
Title: Re: How to - Install Fonts on OS/2
Post by: Ian Manners on October 26, 2017, 04:39:31 pm
Copy/install the fonts into x:\PSFONTS,

Then open the System folder, System Setup, and Fonts folder. If the font's do not appear in the fonts folder you can drag and drop the font file icon from the directory you placed it in (assume x:\PSFONTS) to the now open Fonts folder. Depends on the state of the folder update setting in XWorkplace setup. That is how it works with OS/2 and XWorkplace.
Title: Re: How to - Install Fonts on OS/2
Post by: Dave Yeo on October 26, 2017, 04:48:48 pm
In ArcaOS, it seems to be Computer-->System Setup->Appearance-->Fonts.
Title: Re: How to - Install Fonts on OS/2
Post by: Pete on October 26, 2017, 05:14:35 pm
Hi All

In ArcaOS, it seems to be Computer-->System Setup->Appearance-->Fonts.


Well, that is different to my ArcaOS installation where it is Computer-->System Setup->Fonts.

I just copied Droid Sans and Droid Serif fonts from my eCS2.2beta2 installation L:\PSFONTS to my ArcaOS installation M:\PSFONTS.

I then opened  Computer-->System Setup->Fonts and see that the Droid fonts are shown. Doubleclicking any of the Droid fonts results in the font opening in the font viewer. The Droid fonts are available for selection in applications.


Maybe Devon was playing with the flaky Font Palette?


Regards

Pete


Regards

Pete


Title: Re: How to - Install Fonts on OS/2
Post by: Dave Yeo on October 26, 2017, 05:23:00 pm
Yea, I was referring to the font palette.
Title: Re: How to - Install Fonts on OS/2
Post by: warpsalad on October 27, 2017, 01:44:06 pm
Unfortunately copying the fonts to C:\PSFONTS (which is what I did last time) doesn't seem to allow the fonts to appear in the font viewer. Doesn't matter how many I copy, still shows 109 in the 'Fonts' viewer folder.

I can't drag and drop any files as this setting is disabled by default on ArcaOS (unlike OS/2 Warp), and any changes to the mouse settings don't seem restore it.
Title: Re: How to - Install Fonts on OS/2
Post by: xynixme on October 27, 2017, 02:18:32 pm
I can't drag and drop any files as this setting is disabled by default on ArcaOS (unlike OS/2 Warp), and any changes to the mouse settings don't seem restore it.

</silence>Sample CMD file:
Code: [Select]
REM I am not using AO. I am assuming the use of the INSTFONT utility.
C:
CD \PSFONTS
FOR %F IN (*.TTF) DO (INSTFONT C:\PSFONTS\%F)
REM Do expect error messages of already installed TTF fonts.
<silence>
Title: Re: How to - Install Fonts on OS/2
Post by: Dave Yeo on October 27, 2017, 04:42:13 pm
Unfortunately copying the fonts to C:\PSFONTS (which is what I did last time) doesn't seem to allow the fonts to appear in the font viewer. Doesn't matter how many I copy, still shows 109 in the 'Fonts' viewer folder.

I can't drag and drop any files as this setting is disabled by default on ArcaOS (unlike OS/2 Warp), and any changes to the mouse settings don't seem restore it.

Use the font palette.
Title: Re: How to - Install Fonts on OS/2
Post by: warpsalad on October 28, 2017, 10:59:44 am
Use the font palette.
Unfortunately the font palette also requires you to have the ability to drag and drop. But after going through ArcaOS documentation in the OS/2 help file, they changed the drag to the right button instead of the left...

Strangely enough dragging an icon into the font palette in ArcaOS does nothing, but fortunately dragging it into the original font view does install it.

I opened up the font and it does nothing to OS/2, so it's exclusive to Microsoft's "OS/2 font table" that's still a part of Windows.
Title: Re: How to - Install Fonts on OS/2
Post by: Dave Yeo on October 28, 2017, 06:28:23 pm
Actually to use the font palette to install a font, you have to click Edit font, then Add...  and change the default of A: to where the font currently is.

BTW, dragging with button 2 has always been the default. You can change it in the mouse object under the mappings tab
Title: Re: How to - Install Fonts on OS/2
Post by: Alfredo Fernández Díaz on December 05, 2017, 08:08:28 pm
Unfortunately the font palette also requires you to have the ability to drag and drop. But after going through ArcaOS documentation in the OS/2 help file, they changed the drag to the right button instead of the left...
As Dave said, OS/2 default for dragging was always MB2 (usually the one on the right).

Quote
Strangely enough dragging an icon into the font palette in ArcaOS does nothing, but fortunately dragging it into the original font view does install it.
You drag "fonts" (an abstract construct for "font settings") from the palette and drop them onto any UI bit you want to use them to display text; you drag font _files_ (not icons) to the "fonts" folder in System Configuration to have them installed and used by the system (i.e. before you can see them in the palette). The similarity in names may be confusing.

Quote
I opened up the font and it does nothing to OS/2, so it's exclusive to Microsoft's "OS/2 font table" that's still a part of Windows.
The problem reported seems to be in Windows (win32k.sys) handling of TTF files with a malformed/corrupted OS/2 table (an internal structure of the font file intended for use under OS/2). I would think Windos should ignore that, but hey... OTOH a TTF file with a corrupt OS/2 table is likely to not work, or stir trouble, depending on how well your OS/2 TTF driver (IIRC truetype.dll or freetype.dll) handles the corrupt data.
Title: Re: How to - Install Fonts on OS/2
Post by: warpsalad on December 16, 2017, 12:31:07 pm
The problem reported seems to be in Windows (win32k.sys) handling of TTF files with a malformed/corrupted OS/2 table (an internal structure of the font file intended for use under OS/2). I would think Windos should ignore that, but hey... OTOH a TTF file with a corrupt OS/2 table is likely to not work, or stir trouble, depending on how well your OS/2 TTF driver (IIRC truetype.dll or freetype.dll) handles the corrupt data.

Nope, the "OS/2" Font Table was consolidated to work with both Windows and OS/2, and to this day is still used under Windows (I was not joking when I said the OS/2 font table is still present under Windows 7 and 10):
http://typedrawers.com/discussion/501/can-someone-explain-the-origin-of-the-os-2-tables-name
Title: Re: How to - Install Fonts on OS/2
Post by: Alfredo Fernández Díaz on December 17, 2017, 11:37:03 am
I was actually kinda surprised a couple of times that 'modern' font software still generated an 'OS/2' table, or leave it intact. I assumed Windows would have started to use its own one shortly after the big split, and that it would be called something different -- but I rarely browse binary files to find out what is inside as long as software works. You live and learn ;)
Title: Re: How to - Install Fonts on OS/2
Post by: Jan-Erik Lärka on January 07, 2018, 12:53:59 am
You can also try a REXX script that can add .ttf-files
This script can extract and add them from .zip-files and WarpIn Packages as well
Title: Re: How to - Install Fonts on OS/2
Post by: Alex Taylor on January 07, 2018, 01:28:02 am
You can also try a REXX script that can add .ttf-files
This script can extract and add them from .zip-files and WarpIn Packages as well

That one will require a reboot to make the font available, though.

Maybe I should add a function to RXUTILEX.DLL for registering fonts without a reboot... well, something for the wish list, perhaps. :)
Title: Re: How to - Install Fonts on OS/2
Post by: Jan-Erik Lärka on January 07, 2018, 09:34:21 am
That one will require a reboot to make the font available, though.

Maybe I should add a function to RXUTILEX.DLL for registering fonts without a reboot... well, something for the wish list, perhaps. :)
I wouldn't mind if RXUTILEX.DLL would contain a function to register one or more fonts.
By the way, the script is a variation to the one Alex Taylor provide on his site.
Title: Re: How to - Install Fonts on OS/2
Post by: Alex Taylor on January 07, 2018, 10:37:44 pm
That one will require a reboot to make the font available, though.

Maybe I should add a function to RXUTILEX.DLL for registering fonts without a reboot... well, something for the wish list, perhaps. :)
I wouldn't mind if RXUTILEX.DLL would contain a function to register one or more fonts.
By the way, the script is a variation to the one Alex Taylor provide on his site.

Huh? I don't provide any script like that on my site...

I do provide an executable, which works in an entirely different way (and does not require a reboot).
Title: Re: How to - Install Fonts on OS/2
Post by: Jan-Erik Lärka on January 08, 2018, 12:25:13 pm
Ehm... Think I found the code with a prevoid version of freetype/2 then