* added a way to get the unscaled pensize (ie that of the current draw state

of a view)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21852 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stephan Aßmus 2007-08-08 18:29:09 +00:00
parent 8a44618225
commit aaa42c7e22
2 changed files with 13 additions and 0 deletions

View File

@ -496,6 +496,18 @@ DrawState::PenSize() const
}
//! returns the unscaled pen size
float
DrawState::UnscaledPenSize() const
{
// NOTE: As documented in the BeBook,
// pen size is never smaller than 1.0.
// This is supposed to be the smallest
// possible device size.
return max_c(fPenSize, 1.0);
}
//! sets the font to be already scaled by fScale
void
DrawState::SetFont(const ServerFont& font, uint32 flags)

View File

@ -108,6 +108,7 @@ class DrawState {
void SetPenSize(float size);
float PenSize() const;
float UnscaledPenSize() const;
// font
void SetFont(const ServerFont& font,