Added GetFamilyAndStyle
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10975 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -76,6 +76,7 @@ public:
|
||||
const char *GetPath(void) const { return fStyle->GetPath(); }
|
||||
uint16 StyleID(void) const { return fStyle->GetID(); }
|
||||
uint16 FamilyID(void) const { return fStyle->Family()->GetID(); }
|
||||
uint32 GetFamilyAndStyle(void);
|
||||
|
||||
BRect BoundingBox(void);
|
||||
void Height(font_height *fh);
|
||||
|
||||
@@ -186,3 +186,18 @@ void ServerFont::SetFamilyAndStyle(const uint32 &fontID)
|
||||
if(sty)
|
||||
fStyle=sty;
|
||||
}
|
||||
|
||||
/*!
|
||||
\brief Gets the ID values for the ServerFont instance in one shot
|
||||
\return the combination of family and style ID numbers
|
||||
*/
|
||||
uint32 ServerFont::GetFamilyAndStyle(void)
|
||||
{
|
||||
uint32 famsty=0;
|
||||
|
||||
famsty|=FamilyID() << 16;
|
||||
famsty|=StyleID();
|
||||
|
||||
return famsty;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user