123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141 |
- class CD_IUP
- inherit
- CANVAS_DRAW
- CD_CANVAS_SIMULATE
- CD_CANVAS_INITIALIZATION
- CD_CANVAS_CONTROL
- CD_CANVAS_COORDINATE_SYSTEM
- CD_CANVAS_WORLD_COORDINATES
- CD_CANVAS_GENERAL_ATTRIBUTES
- CD_PRIMITIVES_MARKS
- CD_LINES
- CD_POLYGONS_BEZIER_REGIONS
- CD_COMPLEX_CLIPPING_REGIONS
- CD_FILLED_AREAS
- CD_TEXT
- CD_VECTOR_TEXT
- CD_CLIENT_IMAGES
- create {IUP_CANVAS}
- create_with_front_cd_canvas
- create {IUP_CONTROLS}
- create_with_cd_canvas
- create {ANY}
- create_with_canvas,
- create_double_buffer_with_canvas,
- create_double_buffer_rgb_with_canvas
- feature {IUP_CANVAS}
- create_with_front_cd_canvas (p: POINTER)
- do
- cnvs := p
- end
- feature {IUP_CONTROLS}
- create_with_cd_canvas (wgt: IUP_CANVAS; p: POINTER)
- do
- cnvs := p
- wgt.set_cd_canvas(Current)
- initialize_modes
- initialize_colors
- end
-
- feature {ANY}
- create_with_canvas (wgt: IUP_CANVAS)
- do
- cnvs := int_create_canvas(int_cd_context_iup, wgt.widget)
- wgt.set_cd_canvas(Current)
- initialize_modes
- initialize_colors
- end
- create_double_buffer_with_canvas (wgt: IUP_CANVAS)
- do
- cnvs := int_create_canvas(int_cd_context_iup_double_buffer, wgt.widget)
- wgt.set_back_and_front_cd_canvas(Current)
- initialize_modes
- initialize_colors
- end
- create_double_buffer_rgb_with_canvas (wgt: IUP_CANVAS)
- do
- cnvs := int_create_canvas(int_cd_context_iup_double_buffer_rgb,
- wgt.widget)
- wgt.set_back_and_front_cd_canvas(Current)
- initialize_modes
- initialize_colors
- end
- feature {}
- -- Internals
- int_create_canvas (context, data: POINTER): POINTER
- external "plug_in"
- alias "{
- location: "${sys}/plugins"
- module_name: "iup"
- feature_name: "cdCreateCanvas"
- }"
- end
- int_cd_context_iup: POINTER
- external "plug_in"
- alias "{
- location: "${sys}/plugins"
- module_name: "iup"
- feature_name: "cdContextIup()"
- }"
- end
- int_cd_context_iup_double_buffer: POINTER
- external "plug_in"
- alias "{
- location: "${sys}/plugins"
- module_name: "iup"
- feature_name: "cdContextIupDBuffer()"
- }"
- end
- int_cd_context_iup_double_buffer_rgb: POINTER
- external "plug_in"
- alias "{
- location: "${sys}/plugins"
- module_name: "iup"
- feature_name: "cdContextIupDBufferRGB()"
- }"
- end
- end
- -- The MIT License (MIT)
- -- Copyright (c) 2016, 2017 by German A. Arias
- -- Permission is hereby granted, free of charge, to any person obtaining a copy
- -- of this software and associated documentation files (the "Software"), to deal
- -- in the Software without restriction, including without limitation the rights
- -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- -- copies of the Software, and to permit persons to whom the Software is
- -- furnished to do so, subject to the following conditions:
- --
- -- The above copyright notice and this permission notice shall be included in
- -- all copies or substantial portions of the Software.
- --
- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- -- SOFTWARE.
|