7#include "xfa/fxfa/cxfa_ffline.h"
9#include "third_party/base/notreached.h"
10#include "xfa/fgas/graphics/cfgas_gecolor.h"
11#include "xfa/fgas/graphics/cfgas_gegraphics.h"
12#include "xfa/fgas/graphics/cfgas_gepath.h"
13#include "xfa/fxfa/parser/cxfa_edge.h"
14#include "xfa/fxfa/parser/cxfa_line.h"
15#include "xfa/fxfa/parser/cxfa_value.h"
36void CXFA_FFLine::GetRectFromHand(
CFX_RectF& rect,
39 float fHalfWidth = fLineWidth / 2.0f;
43 rect
.top -= fHalfWidth;
46 rect
.top += fHalfWidth;
51 NOTREACHED_NORETURN();
53 }
else if (rect
.width < 1.0f) {
56 rect
.left += fHalfWidth;
59 rect
.left += fHalfWidth;
64 NOTREACHED_NORETURN();
77 NOTREACHED_NORETURN();
88 CXFA_Value* value = m_pNode->GetFormValueIfExists();
92 FX_ARGB lineColor = 0xFF000000;
93 float fLineWidth = 1.0f;
114 CXFA_Margin* margin = m_pNode->GetMarginIfExists();
119 CFGAS_GEPath linePath;
122 linePath
.AddLine(rtLine.TopRight()
, rtLine.BottomLeft()
);
124 linePath
.AddLine(rtLine.TopLeft()
, rtLine.BottomRight()
);
CFGAS_GEColor(const FX_ARGB argb)
StateRestorer(CFGAS_GEGraphics *graphics)
void SetLineWidth(float lineWidth)
void SetStrokeColor(const CFGAS_GEColor &color)
void SetLineCap(CFX_GraphStateData::LineCap lineCap)
void StrokePath(const CFGAS_GEPath &path, const CFX_Matrix &matrix)
void AddLine(const CFX_PointF &p1, const CFX_PointF &p2)
void Concat(const CFX_Matrix &right)
void Inflate(float x, float y)
void Deflate(float x, float y)
void RenderWidget(CFGAS_GEGraphics *pGS, const CFX_Matrix &matrix, HighlightOption highlight) override
CXFA_Edge * GetEdgeIfExists()
XFA_AttributeValue GetHand()
XFA_AttributeValue GetCapType()
float GetThickness() const
XFA_AttributeValue GetStrokeType()
CXFA_Line * GetLineIfExists() const
void XFA_StrokeTypeSetLineDash(CFGAS_GEGraphics *pGraphics, XFA_AttributeValue iStrokeType, XFA_AttributeValue iCapType)