Rhino C++ API  8.6
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
ON_PANOSE1 Class Reference

https://monotype.github.io/panose/pan1.htm More...

#include <opennurbs_font.h>

Public Types

enum  FamilyKind : ON__UINT8 {
  FamilyKind::Any = 0, FamilyKind::NoFit = 1, FamilyKind::LatinText = 2, FamilyKind::LatinScript = 3,
  FamilyKind::LatinDecorative = 4, FamilyKind::LatinSymbol = 5
}
 PANOSE 1.0 font family kind More...
 

Public Member Functions

 ON_PANOSE1 ()=default
 
 ON_PANOSE1 (const ON_PANOSE1 &)=default
 
 ~ON_PANOSE1 ()=default
 
void Dump (class ON_TextLog &text_log) const
 
bool IsSet () const
 
bool IsZero () const
 
bool IsZeroOrOne () const
 
ON_PANOSE1operator= (const ON_PANOSE1 &)=default
 
ON_PANOSE1::FamilyKind PANOSE1FamilyKind () const
 
bool Read (class ON_BinaryArchive &archive)
 
void SetNineBytes (ON_PANOSE1::FamilyKind family_kind, const ON__UINT8 *panose1_properties_bytes)
 
void SetTenBytes (const ON__UINT8 *panose1_ten_bytes)
 
const ON__UINT8TenBytes () const
 
bool Write (class ON_BinaryArchive &archive) const
 

Static Public Member Functions

static ON_PANOSE1::FamilyKind FamilyKindFromUnsigned (unsigned int unsigned_panose_family_kind)
 
static const wchar_t * FamilyKindToWideString (ON_PANOSE1::FamilyKind family_kind)
 

Static Public Attributes

static const ON_PANOSE1 Zero
 All PANOSE 1.0 values are zero, which means (Any,Any,...,Any) More...
 

Detailed Description

https://monotype.github.io/panose/pan1.htm

Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.

THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.

For complete openNURBS copyright information see http://www.opennurbs.org.


Member Enumeration Documentation

◆ FamilyKind

PANOSE 1.0 font family kind

The overall genre of the alphabet or script that is being described is signified by the Family Kind digit. This digit consists of two parts: the script kind identifier and the genre kind identifier. In this case, the script identifier is Latin, and the genre type is described as Text, Hand Written, Decorative or Symbol. The Family Kind digit is not controlled by specific measurements, and there has been no attempt to mathematically determine the appropriate category for a given font design. Visual and aesthetic classification of Latin faces that are obviously script, decorative, or symbol fonts is required.


Enumerator
Any 

"Any" means match that digit with any available digit, which allows the mapper to handle distortable typefaces.

NoFit 

"No Fit" means that the item being classified does not fit within the PANOSE 1.0 classification system.

LatinText 

To decide whether a font belongs to the Latin Text group follow the two step process below.

A. Answer the following three questions. If they are all yes, then it belongs in this group. If the answer is still ambiguous, go to step B.

Does the font belong to a family that includes italic versions? Most fonts in this group have a variety of weights and most include italic versions.

Are the characters in the font made up of standard topologies constructed of standard parts?

Is some portion of the font suitable for composing a paragraph of text?

B. As a final tie breaker, look at the second digit of the Decorative (Section 4) and Handwritten (Section 3) families and see if there is something in them that fits the font in question better. https://monotype.github.io/panose/pan2.htm

LatinScript 

Many fonts are clearly scripts and unrelated to any book face. On occasion, though, the distinction gets rather vague. A good rule of thumb is that if the cursive font is part a family that includes a book face, then it should be classified in the Latin Text group. If it is freestanding with no obvious related book face, then it falls into the Latin Hand Written group. This can be a bit difficult to determine, since a font house may only choose to provide the cursive from a larger family, so the classifier needs to think about the face being processed and not do it purely by rote. https://monotype.github.io/panose/pan3.htm

LatinDecorative 

Latin Decorative faces are those that are designed more for impact than readability. Usually Decoratives are used singly or in small groups, for special purposes. Small cap fonts are also included in this group because they have become unusual enough to be considered special purpose fonts. https://monotype.github.io/panose/pan4.htm

LatinSymbol 

Latin Symbol is where all the nonalphabetic fonts reside. These are fonts that can be loaded like normal text fonts, but do not contain readable characters. Dingbats and specialized symbol fonts are two examples. https://monotype.github.io/panose/pan5.htm

Constructor & Destructor Documentation

◆ ON_PANOSE1() [1/2]

ON_PANOSE1::ON_PANOSE1 ( )
default

◆ ~ON_PANOSE1()

ON_PANOSE1::~ON_PANOSE1 ( )
default

◆ ON_PANOSE1() [2/2]

ON_PANOSE1::ON_PANOSE1 ( const ON_PANOSE1 )
default

Member Function Documentation

◆ Dump()

void ON_PANOSE1::Dump ( class ON_TextLog text_log) const

◆ FamilyKindFromUnsigned()

static ON_PANOSE1::FamilyKind ON_PANOSE1::FamilyKindFromUnsigned ( unsigned int  unsigned_panose_family_kind)
static

Special values "Any" (0) and "No Fit" (1) exist for every category, which have specific meanings to the mapper.
Description: In the rare cases when an ON_PANOSE1::Classification value must be passed as an unsigned int, use ON_PANOSE1::ClassificationFromUnsigned() to convert the unsigned value to an ON_PANOSE1::Classification value. Parameters: unsigned_panose_family_kind - [in]

◆ FamilyKindToWideString()

static const wchar_t* ON_PANOSE1::FamilyKindToWideString ( ON_PANOSE1::FamilyKind  family_kind)
static

◆ IsSet()

bool ON_PANOSE1::IsSet ( ) const

Returns: True if some PANOSE 1.0 value is not zero and not one. This means this PANOSE 1.0 information may be useful in searching for similar fonts.

◆ IsZero()

bool ON_PANOSE1::IsZero ( ) const

Returns: True if every PANOSE 1.0 value is zero which means there is no useful font classification information in the instance.

◆ IsZeroOrOne()

bool ON_PANOSE1::IsZeroOrOne ( ) const

Returns: True if every PANOSE 1.0 value is zero or one which means there is no useful font classification information in the instance.

◆ operator=()

ON_PANOSE1& ON_PANOSE1::operator= ( const ON_PANOSE1 )
default

◆ PANOSE1FamilyKind()

ON_PANOSE1::FamilyKind ON_PANOSE1::PANOSE1FamilyKind ( ) const

◆ Read()

bool ON_PANOSE1::Read ( class ON_BinaryArchive archive)

◆ SetNineBytes()

void ON_PANOSE1::SetNineBytes ( ON_PANOSE1::FamilyKind  family_kind,
const ON__UINT8 panose1_properties_bytes 
)

Parameters: family_kind - [in] PANOSE 1.0 font Family kind classification panose1_properties_bytes - [in] Array of 9 bytes of PANOSE1 properties

◆ SetTenBytes()

void ON_PANOSE1::SetTenBytes ( const ON__UINT8 panose1_ten_bytes)

Parameters: classification - [in] PANOSE 1.0 font classification panose1_properties_bytes - [in] Array of 9 bytes of PANOSE1 properties

◆ TenBytes()

const ON__UINT8* ON_PANOSE1::TenBytes ( ) const

Returns: A pointer to an array of 10 bytes of PANOSE 1 classification properties. The initial byte is the PANOSE 1 Classification and is identical to the value returned by FontClassification(). The interpretation of the following 9 bytes depends on the value of the first byte. If the initial byte is 0 = ON_FontPANOSE1::Classification::Any (0) or 1 = ON_FontPANOSE1::Classification::NoFit, then these 9 bytes have no meaning.

◆ Write()

bool ON_PANOSE1::Write ( class ON_BinaryArchive archive) const

Member Data Documentation

◆ Zero

const ON_PANOSE1 ON_PANOSE1::Zero
static

All PANOSE 1.0 values are zero, which means (Any,Any,...,Any)