diff --git a/panda/src/display/displayRegion.h b/panda/src/display/displayRegion.h index 4e40ad0695..ce13bbcf15 100644 --- a/panda/src/display/displayRegion.h +++ b/panda/src/display/displayRegion.h @@ -93,7 +93,7 @@ PUBLISHED: virtual void set_camera(const NodePath &camera); INLINE NodePath get_camera(Thread *current_thread = Thread::get_current_thread()) const; - MAKE_PROPERTY(camear, get_camera, set_camera); + MAKE_PROPERTY(camera, get_camera, set_camera); virtual void set_active(bool active); INLINE bool is_active() const; diff --git a/panda/src/display/graphicsStateGuardian.h b/panda/src/display/graphicsStateGuardian.h index 3854bcc75f..53fb346609 100644 --- a/panda/src/display/graphicsStateGuardian.h +++ b/panda/src/display/graphicsStateGuardian.h @@ -247,7 +247,7 @@ PUBLISHED: virtual bool set_gamma(PN_stdfloat gamma); PN_stdfloat get_gamma(PN_stdfloat gamma); virtual void restore_gamma(); - MAKE_PROPERTY(get_gamma, set_gamma); + MAKE_PROPERTY(gamma, get_gamma, set_gamma); INLINE void set_texture_quality_override(Texture::QualityLevel quality_level); INLINE Texture::QualityLevel get_texture_quality_override() const; diff --git a/panda/src/movies/movieAudio.h b/panda/src/movies/movieAudio.h index 810c0acdbf..514b0627ba 100644 --- a/panda/src/movies/movieAudio.h +++ b/panda/src/movies/movieAudio.h @@ -53,6 +53,7 @@ class EXPCL_PANDA_MOVIES MovieAudio : public TypedWritableReferenceCount, public static PT(MovieAudio) get(const Filename &name); INLINE const Filename &get_filename() const; + MAKE_PROPERTY(filename, get_filename); protected: Filename _filename; diff --git a/panda/src/movies/movieVideo.h b/panda/src/movies/movieVideo.h index 354b011f43..225e3e4fc8 100644 --- a/panda/src/movies/movieVideo.h +++ b/panda/src/movies/movieVideo.h @@ -48,7 +48,9 @@ PUBLISHED: INLINE const Filename &get_filename() const; INLINE const SubfileInfo &get_subfile_info() const; - + MAKE_PROPERTY(filename, get_filename); + MAKE_PROPERTY(subfile_info, get_subfile_info); + protected: Filename _filename; SubfileInfo _subfile_info; diff --git a/panda/src/rocket/rocketRegion.h b/panda/src/rocket/rocketRegion.h index cb297ec27a..8f524708ae 100644 --- a/panda/src/rocket/rocketRegion.h +++ b/panda/src/rocket/rocketRegion.h @@ -48,14 +48,17 @@ PUBLISHED: #endif #ifdef HAVE_ROCKET_PYTHON EXTENSION(PyObject *get_context() const); + MAKE_PROPERTY(context, get_context); #endif INLINE void set_input_handler(RocketInputHandler *handler); INLINE RocketInputHandler *get_input_handler() const; + MAKE_PROPERTY(input_handler, get_input_handler, set_input_handler); bool init_debugger(); void set_debugger_visible(bool visible); bool is_debugger_visible() const; + MAKE_PROPERTY(debugger_visible, is_debugger_visible, set_debugger_visible); private: RocketRenderInterface _interface; diff --git a/panda/src/text/dynamicTextFont.I b/panda/src/text/dynamicTextFont.I index d8af7dc340..eff247e51c 100644 --- a/panda/src/text/dynamicTextFont.I +++ b/panda/src/text/dynamicTextFont.I @@ -252,6 +252,17 @@ get_poly_margin() const { return _poly_margin; } +//////////////////////////////////////////////////////////////////// +// Function: DynamicTextFont::set_page_size +// Access: Published +// Description: Sets the x, y size of the textures that are created +// for the DynamicTextFont. +//////////////////////////////////////////////////////////////////// +INLINE void DynamicTextFont:: +set_page_size(const LVecBase2i &page_size) { + _page_size = page_size; +} + //////////////////////////////////////////////////////////////////// // Function: DynamicTextFont::set_page_size // Access: Published diff --git a/panda/src/text/dynamicTextFont.h b/panda/src/text/dynamicTextFont.h index 355f15ee43..8c6f2a71fe 100644 --- a/panda/src/text/dynamicTextFont.h +++ b/panda/src/text/dynamicTextFont.h @@ -53,17 +53,22 @@ PUBLISHED: INLINE bool set_point_size(PN_stdfloat point_size); INLINE PN_stdfloat get_point_size() const; + MAKE_PROPERTY(point_size, get_point_size, set_point_size); INLINE bool set_pixels_per_unit(PN_stdfloat pixels_per_unit); INLINE PN_stdfloat get_pixels_per_unit() const; + MAKE_PROPERTY(pixels_per_unit, get_pixels_per_unit, set_pixels_per_unit); INLINE bool set_scale_factor(PN_stdfloat scale_factor); INLINE PN_stdfloat get_scale_factor() const; + MAKE_PROPERTY(scale_factor, get_scale_factor, set_scale_factor); INLINE void set_native_antialias(bool native_antialias); INLINE bool get_native_antialias() const; + MAKE_PROPERTY(native_antialias, get_native_antialias, set_native_antialias); INLINE int get_font_pixel_size() const; + MAKE_PROPERTY(font_pixel_size, get_font_pixel_size); INLINE PN_stdfloat get_line_height() const; INLINE PN_stdfloat get_space_advance() const; @@ -72,11 +77,15 @@ PUBLISHED: INLINE int get_texture_margin() const; INLINE void set_poly_margin(PN_stdfloat poly_margin); INLINE PN_stdfloat get_poly_margin() const; + MAKE_PROPERTY(texture_margin, get_texture_margin, set_texture_margin); + MAKE_PROPERTY(poly_margin, get_poly_margin, set_poly_margin); + INLINE void set_page_size(const LVecBase2i &page_size); INLINE void set_page_size(int x_size, int y_size); INLINE const LVecBase2i &get_page_size() const; INLINE int get_page_x_size() const; INLINE int get_page_y_size() const; + MAKE_PROPERTY(page_size, get_page_size, set_page_size); INLINE void set_minfilter(SamplerState::FilterType filter); INLINE SamplerState::FilterType get_minfilter() const; @@ -84,11 +93,16 @@ PUBLISHED: INLINE SamplerState::FilterType get_magfilter() const; INLINE void set_anisotropic_degree(int anisotropic_degree); INLINE int get_anisotropic_degree() const; + MAKE_PROPERTY(minfilter, get_minfilter, set_minfilter); + MAKE_PROPERTY(magfilter, get_magfilter, set_magfilter); + MAKE_PROPERTY(anisotropic_degree, get_anisotropic_degree, set_anisotropic_degree); INLINE void set_render_mode(RenderMode render_mode); INLINE RenderMode get_render_mode() const; INLINE void set_winding_order(WindingOrder winding_order); INLINE WindingOrder get_winding_order() const; + MAKE_PROPERTY(render_mode, get_render_mode, set_render_mode); + MAKE_PROPERTY(winding_order, get_winding_order, set_winding_order); INLINE void set_fg(const LColor &fg); INLINE const LColor &get_fg() const; @@ -100,6 +114,9 @@ PUBLISHED: INLINE PN_stdfloat get_outline_width() const; INLINE PN_stdfloat get_outline_feather() const; INLINE Texture::Format get_tex_format() const; + MAKE_PROPERTY(fg, get_fg, set_fg); + MAKE_PROPERTY(bg, get_bg, set_bg); + MAKE_PROPERTY(tex_format, get_tex_format); int get_num_pages() const; DynamicTextPage *get_page(int n) const; diff --git a/panda/src/text/dynamicTextGlyph.h b/panda/src/text/dynamicTextGlyph.h index 39fdec65c2..e52823ad92 100644 --- a/panda/src/text/dynamicTextGlyph.h +++ b/panda/src/text/dynamicTextGlyph.h @@ -45,6 +45,7 @@ PUBLISHED: virtual ~DynamicTextGlyph(); INLINE DynamicTextPage *get_page() const; + MAKE_PROPERTY(page, get_page); INLINE bool intersects(int x, int y, int x_size, int y_size) const; diff --git a/panda/src/text/textFont.h b/panda/src/text/textFont.h index 74de7f1d3e..88b9869f44 100644 --- a/panda/src/text/textFont.h +++ b/panda/src/text/textFont.h @@ -75,9 +75,13 @@ PUBLISHED: INLINE operator bool () const; INLINE PN_stdfloat get_line_height() const; INLINE void set_line_height(PN_stdfloat line_height); + MAKE_PROPERTY(valid, is_valid); + MAKE_PROPERTY(line_height, get_line_height, set_line_height); INLINE PN_stdfloat get_space_advance() const; INLINE void set_space_advance(PN_stdfloat space_advance); + MAKE_PROPERTY(space_advance, get_space_advance, set_space_advance); + INLINE CPT(TextGlyph) get_glyph(int character); virtual void write(ostream &out, int indent_level) const; diff --git a/panda/src/text/textGlyph.h b/panda/src/text/textGlyph.h index 85f10b8509..3097a3a3d1 100644 --- a/panda/src/text/textGlyph.h +++ b/panda/src/text/textGlyph.h @@ -44,6 +44,10 @@ PUBLISHED: INLINE const RenderState *get_state() const; INLINE PN_stdfloat get_advance() const; + MAKE_PROPERTY(character, get_character); + MAKE_PROPERTY(state, get_state); + MAKE_PROPERTY(advance, get_advance); + virtual bool is_whitespace() const; PT(Geom) get_geom(Geom::UsageHint usage_hint) const; diff --git a/panda/src/text/textGraphic.h b/panda/src/text/textGraphic.h index 3a032ca2c9..3b08aec96c 100644 --- a/panda/src/text/textGraphic.h +++ b/panda/src/text/textGraphic.h @@ -48,13 +48,16 @@ PUBLISHED: INLINE NodePath get_model() const; INLINE void set_model(const NodePath &model); + MAKE_PROPERTY(model, get_model, set_model); INLINE LVecBase4 get_frame() const; INLINE void set_frame(const LVecBase4 &frame); INLINE void set_frame(PN_stdfloat left, PN_stdfloat right, PN_stdfloat bottom, PN_stdfloat top); + MAKE_PROPERTY(frame, get_frame, set_frame); INLINE bool get_instance_flag() const; INLINE void set_instance_flag(bool instance_flag); + MAKE_PROPERTY(instance_flag, get_instance_flag, set_instance_flag); private: NodePath _model; diff --git a/panda/src/tform/buttonThrower.h b/panda/src/tform/buttonThrower.h index b779406b05..f62468d773 100644 --- a/panda/src/tform/buttonThrower.h +++ b/panda/src/tform/buttonThrower.h @@ -57,14 +57,25 @@ PUBLISHED: INLINE const string &get_raw_button_down_event() const; INLINE void set_raw_button_up_event(const string &raw_button_up_event); INLINE const string &get_raw_button_up_event() const; + MAKE_PROPERTY(button_down_event, get_button_down_event, set_button_down_event); + MAKE_PROPERTY(button_up_event, get_button_up_event, set_button_up_event); + MAKE_PROPERTY(button_repeat_event, get_button_repeat_event, set_button_repeat_event); + MAKE_PROPERTY(keystroke_event, get_keystroke_event, set_keystroke_event); + MAKE_PROPERTY(candidate_event, get_candidate_event, set_candidate_event); + MAKE_PROPERTY(move_event, get_move_event, set_move_event); + MAKE_PROPERTY(raw_button_down_event, get_raw_button_down_event, set_raw_button_down_event); + MAKE_PROPERTY(raw_button_up_event, get_raw_button_up_event, set_raw_button_up_event); INLINE void set_prefix(const string &prefix); INLINE const string &get_prefix() const; INLINE void set_specific_flag(bool specific_flag); INLINE bool get_specific_flag() const; + MAKE_PROPERTY(prefix, get_prefix, set_prefix); + MAKE_PROPERTY(specific_flag, get_specific_flag, set_specific_flag); INLINE void set_time_flag(bool time_flag); INLINE bool get_time_flag() const; + MAKE_PROPERTY(time_flag, get_time_flag, set_time_flag); void add_parameter(const EventParameter &obj); int get_num_parameters() const; @@ -73,9 +84,11 @@ PUBLISHED: INLINE const ModifierButtons &get_modifier_buttons() const; INLINE void set_modifier_buttons(const ModifierButtons &mods); + MAKE_PROPERTY(modifier_buttons, get_modifier_buttons, set_modifier_buttons); INLINE void set_throw_buttons_active(bool flag); INLINE bool get_throw_buttons_active() const; + MAKE_PROPERTY(throw_buttons_active, get_throw_buttons_active, set_throw_buttons_active); bool add_throw_button(const ModifierButtons &mods, const ButtonHandle &button); bool remove_throw_button(const ModifierButtons &mods, const ButtonHandle &button);