Displaying 3 results from an estimated 3 matches for "prepare_dc".
Did you mean:
prepare_dtb
2007 Apr 28
0
[978] branches/wxruby2/wxwidgets_282/samples/bigdemo/wxScrolledWindow.rbw: Fix crazy crashers on MSW; fix scrolling/drawing position; safe path to bitmap
...ass="lines">@@ -39,15 +40,13 @@
</span><span class="cx"> end
</span><span class="cx">
</span><span class="cx"> def on_paint(event)
</span><del>- dc = Wx::PaintDC.new(self)
- prepare_dc(dc)
- # since we''re not buffering in this case, we have to
- # paint the whole window, potentially very time consuming.
- do_drawing(dc)
</del><ins>+ paint { | dc | do_drawing(dc) }
</ins><span class="cx"> end
<...
2007 Apr 28
0
[976] branches/wxruby2/wxwidgets_282/samples/bigdemo/wxScrolledWindow.rbw: Remove deprecated begin_drawing and end_drawing calls
...lt;/span><span class="cx"> def draw_saved_lines(dc)
</span><span class="lines">@@ -170,14 +167,12 @@
</span><span class="cx"> dc = Wx::ClientDC.new(self)
</span><span class="cx"> prepare_dc(dc)
</span><span class="cx"> end
</span><del>- dc.begin_drawing()
</del><span class="cx"> dc.set_pen(Wx::Pen.new("MEDIUM FOREST GREEN", 4, Wx::SOLID))
</span><span class="cx">...
2007 Apr 29
0
[981] branches/wxruby2/wxwidgets_282/samples/caret/caret.rb: Don''t call PaintDC.new; just refresh() instead of duplicating paint code
...981)
</span><span class="lines">@@ -166,15 +166,14 @@
</span><span class="cx"> caret.hide
</span><span class="cx"> end
</span><span class="cx">
</span><del>- dc = PaintDC.new(self)
- prepare_dc(dc)
- dc.clear
</del><ins>+ paint do | dc |
+ dc.clear
+ dc.set_font(@font)
</ins><span class="cx">
</span><del>- dc.set_font(@font)
-
- for y in 0 ... @y_chars
- line = @text[@x_chars * y,@x_chars]
- dc.draw_text( line,...