#ifdef __cplusplus extern "C" { #endif #pragma once #include "HROOT-coreType.h" #include "STDDeletable.h" #include "stdcxxType.h" #define TATTLINE_DECL_VIRT(Type) \ short Type##_GetLineColor ( Type##_p p );\ short Type##_GetLineStyle ( Type##_p p );\ short Type##_GetLineWidth ( Type##_p p );\ void Type##_ResetAttLine ( Type##_p p, const char* option );\ void Type##_SetLineAttributes ( Type##_p p );\ void Type##_SetLineColor ( Type##_p p, short lcolor );\ void Type##_SetLineStyle ( Type##_p p, short lstyle );\ void Type##_SetLineWidth ( Type##_p p, short lwidth ); #define TATTLINE_DECL_NONVIRT(Type) \ Type##_p Type##_newTAttLine ( short lcolor, short lstyle, short lwidth );\ int Type##_tAttLine_DistancetoLine ( Type##_p p, int px, int py, double xp1, double yp1, double xp2, double yp2 ); #define TATTLINE_DECL_ACCESSOR(Type) \ #define TATTLINE_DEF_VIRT(Type) \ short Type##_GetLineColor ( Type##_p p ) {\ return ((TYPECASTMETHOD(Type, GetLineColor, TAttLine))(p))->GetLineColor();\ }\ \ short Type##_GetLineStyle ( Type##_p p ) {\ return ((TYPECASTMETHOD(Type, GetLineStyle, TAttLine))(p))->GetLineStyle();\ }\ \ short Type##_GetLineWidth ( Type##_p p ) {\ return ((TYPECASTMETHOD(Type, GetLineWidth, TAttLine))(p))->GetLineWidth();\ }\ \ void Type##_ResetAttLine ( Type##_p p, const char* option ) {\ ((TYPECASTMETHOD(Type, ResetAttLine, TAttLine))(p))->ResetAttLine(option);\ }\ \ void Type##_SetLineAttributes ( Type##_p p ) {\ ((TYPECASTMETHOD(Type, SetLineAttributes, TAttLine))(p))->SetLineAttributes();\ }\ \ void Type##_SetLineColor ( Type##_p p, short lcolor ) {\ ((TYPECASTMETHOD(Type, SetLineColor, TAttLine))(p))->SetLineColor(lcolor);\ }\ \ void Type##_SetLineStyle ( Type##_p p, short lstyle ) {\ ((TYPECASTMETHOD(Type, SetLineStyle, TAttLine))(p))->SetLineStyle(lstyle);\ }\ \ void Type##_SetLineWidth ( Type##_p p, short lwidth ) {\ ((TYPECASTMETHOD(Type, SetLineWidth, TAttLine))(p))->SetLineWidth(lwidth);\ } #define TATTLINE_DEF_NONVIRT(Type) \ Type##_p Type##_newTAttLine ( short lcolor, short lstyle, short lwidth ) {\ Type* newp=new Type(lcolor, lstyle, lwidth);return from_nonconst_to_nonconst(newp);\ }\ \ int Type##_tAttLine_DistancetoLine ( Type##_p p, int px, int py, double xp1, double yp1, double xp2, double yp2 ) {\ return ((TYPECASTMETHOD(Type, tAttLine_DistancetoLine, TAttLine))(p))->DistancetoLine(px, py, xp1, yp1, xp2, yp2);\ } #define TATTLINE_DEF_ACCESSOR(Type) \ DELETABLE_DECL_VIRT(TAttLine) TATTLINE_DECL_VIRT(TAttLine) TATTLINE_DECL_NONVIRT(TAttLine) TATTLINE_DECL_ACCESSOR(TAttLine) #ifdef __cplusplus } #endif