Displaying 20 results from an estimated 98 matches for "set_sizer".
Did you mean:
set_size
2006 Dec 12
0
[785] trunk/wxruby2/doc/textile/window.txtl: Remove set_constraints, correct docs for set_dimensions and set_size
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" /><style type="text/css"><!--
#msg dl { border: 1px #006 solid; background: #369; padding:
2007 Jan 22
4
Adding sizers to other sizers doesn''t work
...up a GUI with a differing number of
widgets per row, resulting in a differing number or widgets per column.
At first I tried to simply do something like the following:
class CharacterInfoPanel < Wx::Panel
def initialize(parent)
super(parent)
sizer = Wx::BoxSizer.new(Wx::VERTICAL)
set_sizer(sizer)
row = Wx::Panel.new(self,-1)
row_sizer = Wx::BoxSizer.new(Wx::HORIZONTAL)
row.set_sizer(row_sizer)
row_sizer.add(Wx::StaticText.new(self, -1, "Character Name"))
row_sizer.add(Wx::Panel.new(self,-1, Wx::DEFAULT_POSITION, Wx::Size.new
(10,1)))
row_sizer.add(W...
2005 May 03
4
Wx::HtmlWindow.on_link_clicked
...')
end
def on_link_clicked(link)
@shell.call 0, ''open'', link.get_href, nil, nil, 1
end
end
class App < Wx::App
def on_init
dialog = Wx::Dialog.new nil, -1, ''About''
sizer = Wx::BoxSizer.new Wx::VERTICAL
dialog.set_sizer sizer
html = WrappedHtml.new dialog, -1
html.set_page <<EOF
<html>
<body>
<a href="http://favicon.ru/en/">My wife web project</a><br />
<a href="mailto:dmiceman@mail.ru">mail me</a><br />
</body>
</ht...
2009 Mar 23
3
How to put a background image on a panel
Well I''ve made a lot of progress on my app, but I''m stuck on figuring
out how to add a bitmap. I have a notebook and a page panel. On this
panel I want to put a backdrop image and scale it to the size of the
panel. How do I do this? I looked at some of the samples related to
bitmaps and I could not see how to apply that to my situation.
Thanks,
T.
2006 Aug 26
7
Progress on crashing
...s a testbed to try to get rid of
crashing problems. Earlier today, it would crash for me almost
immediately, every time. Now, I was able to get about 50 turns into the
game!
I mentioned the first big change in a different email. The new change I
just checked in was to add the DISOWN flag to Window#set_sizer. This is
the first time (that I know of) that we are really taking advantage of
the new SWIG 1.3.29 memory handling features.
When a sizer is created in ruby, SWIG assumes that ruby owns it and will
eventually delete it. But when you pass it to Window#set_sizer, wx now
assumes IT has ownership, an...
2007 Feb 19
2
Sizer question
...Here''s an example of my code:
parent = Wx::Panel.new(frame, -1, Wx::Point.new(0, 0), Wx::Size.new
(823, 900))
sizer = Wx::BoxSizer.new(Wx::VERTICAL)
child = Wx::Panel.new(parent, -1, Wx::Point.new(0, 0), Wx::Size.new
(823, 200))
sizer.add(child, 1, Wx::ALIGN_CENTER_HORIZONTAL, 0)
parent.set_sizer(sizer)
When I resize the window, the size of the child panel grows to
consume the entire height of the parent. I''d like the child''s height
to remain 200. I''ve tried:
- child.set_max_size(Size.new(823, 200))
- sizer.add(child, 1, 0|Wx::ALIGN_CENTER_HORIZONTAL, 0...
2006 Jun 01
1
[PATCH] Make xentrace hypercall a bit more sane
xentrace, setsize and the hypervisor don''t seem to be on the same
page. If tracing is not enabled, the hypercall will only allow
TBUF_SET_SIZE and TBUF_ENABLE. However, set_size calls TBUF_GET_INFO,
and xentrace wants to call TBUF_SET_EVT_MASK and TBUF_SET_CPU_MASK
before calling TBUF_ENABLE.
I don''t see any reason not to call SET_*_MASK and GET_INFO if tracing
is not enabled.
2006 Aug 24
5
TreeCtrl background?
...b:30
Using the following (probably overly verbose) program:
require ''wx''
include Wx
class MyFrame < Frame
def initialize(title)
super(nil, -1, title)
@top_sizer = BoxSizer.new( Wx::VERTICAL )
@panel = Panel.new(self)
@panel.set_auto_layout(true)
@panel.set_sizer(@top_sizer)
@test_text_ctrl = TextCtrl.new(@panel, -1, "")
style = @test_text_ctrl.get_default_style()
style.set_background_colour(WHITE)
@test_text_ctrl.set_default_style(style)
@top_sizer.add(@test_text_ctrl, 0, Wx::EXPAND | Wx::RIGHT, 20)
end
end
class MyApp &...
2007 Sep 03
1
API survey results & update
Thanks to everyone who voted in the API style survey. We had 10 votes
altogether - we''re not electing the prime minister, after all - but it
was decisively a yes. 90% (9/10) supported adding keyword constructors,
and 77% (7/9) ruby-style accessors. The changes are summarised at the
bottom of the email.
We hope to have a 1.9.1 release incorporating these in the next week or
two.
2015 Jul 13
2
[PATCH 1/2] utils: import parse_size from libguestfs
---
src/utils.ml | 21 +++++++++++++++++++++
src/utils.mli | 3 +++
2 files changed, 24 insertions(+)
diff --git a/src/utils.ml b/src/utils.ml
index 3e81c21..7ae24bd 100644
--- a/src/utils.ml
+++ b/src/utils.ml
@@ -204,3 +204,24 @@ let compare_architecture a1 a2 =
exit 1
in
compare (index_of_architecture a1) (index_of_architecture a2)
+
+(* Parse a size field, eg. "10G".
2007 Apr 16
0
[969] branches/wxruby2/wxwidgets_282/doc/textile/window.txtl: Cleanup and fixing of broken links.
...157,7 +1155,7 @@
</span><span class="cx"> "Sizer":sizer.html *get_sizer*()
</span><span class="cx">
</span><span class="cx"> Return the sizer associated with the window by a previous call to
</span><del>-"set_sizer()":#Window_setsizer() or @NULL@.
</del><ins>+"set_sizer":#Window_setsizer or @nil@.
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_gettextextent). Window#get_text_ext...
2007 Apr 29
8
wxruby unfriendly to other threads?
I''ve seen a few e-mails about multithreading with respect to wxruby
but nothing recent. Unless I''m mistaken, and that may be, there
still appear to be problems.
The following code seems to hang my spawned thread in favor of the
wxruby event loop:
Thread.new do
puts "in thread"
loop do
sleep 5
puts "looping"
end
end
puts "main
2007 Jul 21
0
[1139] trunk/wxruby2/samples/text/textctrl.rb: Place TextCtrl sample in a panel so gets correct bg color on MSW
...">
</span><del>- @log = LogTextCtrl.new(self)
</del><ins>+ @log = LogTextCtrl.new(panel)
</ins><span class="cx"> sizer.add(@log, 1, Wx::GROW|Wx::ALL, 2)
</span><span class="cx">
</span><del>- self.set_sizer( sizer )
</del><ins>+ panel.set_sizer( sizer )
</ins><span class="cx"> end
</span><span class="cx">
</span><span class="cx"> def populate_textctrl()
</span></span></pre>
</div>
</div>...
2007 Jul 21
0
[1138] trunk/wxruby2/samples/html/html.rb: Place HTMLWindow in a panel so gets correct bg color on MSW
...)
</span><span class="cx"> @html_win.set_related_status_bar(2)
</span><span class="cx"> @html_win.set_page(DATA.read)
</span><span class="cx"> sizer.add(@html_win, 1, Wx::ALL|Wx::GROW, 4)
</span><del>- self.set_sizer(sizer)
</del><ins>+ panel.set_sizer(sizer)
</ins><span class="cx"> end
</span><span class="cx">
</span><span class="cx"> def setup_menus
</span></span></pre>
</div>
</div>
</body&...
2004 Jun 02
13
wxGrid Question
When operating with a wxGrid is there a way to get a reference to the
TextCtrl field that is created when you start typing in a cell.
Also is there a way to get mouse events to work with a wxGrid, so far I
can''t get any of them to work. I had tried various combo''s of:
@grid.evt_left_down(){ |event|
puts "Left mouse is down"; }
using evt_left_down, evt_left_up,
2019 Jul 09
6
Dovecot 2.3.6 on Solaris10: build issues, segfaults
Hopefully, there is some fix for issue 3 which is beyond my
skill to fix.
Issue 1) Need recent gcc version
Building Dovecot versions <=2.2.x using gcc 3.4.4 worked,
but this gcc version fails to build 2.3.x properly: symptoms
include compile failures and executable crashes that depended
on the amount of optimization used, which is usually a sign of
compiler bugs. (It could also be
2015 Jul 13
0
[PATCH 2/2] Add --size for ext2 filesystem
Add a --size option to setting the size of the ext2 filesystem,
so it is possible to create ext2 appliances with smaller disk images.
The default is like the previously hardcoded value of 4GB.
---
src/build.ml | 4 ++--
src/ext2.ml | 19 ++++++++++---------
src/prepare.ml | 2 +-
src/supermin.ml | 9 +++++++--
src/supermin.pod | 15 +++++++++++++++
5 files changed, 35
2006 Oct 19
0
[691] trunk/wxruby2/samples/calendar/calendar.rb: Placed controls within a panel so they appear on the correct themed background
...add(@calendar, 0)
- @sizer.add(@date, 1)
- @sizer.set_size_hints(self)
</del><ins>+ @sizer.add(@calendar, 0, Wx::ALIGN_CENTRE|Wx::ALL, 5)
+ @sizer.set_size_hints(@panel)
</ins><span class="cx"> layout
</span><del>- set_sizer(@sizer)
</del><ins>+ @panel.set_sizer(@sizer)
+ set_best_fitting_size
</ins><span class="cx"> end
</span><span class="cx">
</span><span class="cx"> def on_quit
</span><span class="li...
2004 Apr 21
2
Resizing a ListCtrl
...ONTAL)
# File List {{{
@fileList = ListCtrl.new(self, -1, DEFAULT_POSITION, Size.new(250,
200),
LC_REPORT | LC_SINGLE_SEL)
fillListCtrl()
centerSizer.add(@fileList, 6, GROW|EXPAND)
# }}}
@dlgSizer.add(centerSizer, 1)
@dlgSizer.set_size_hints(self)
set_sizer(@dlgSizer)
# end main layout }}}
## global events {{{
evt_close {onClose}
evt_size() {|event| onSize(event) }
# }}}
end ## }}}
def onClose ## {{{
destroy()
end ## }}}
def onSize(event=nil)
frame_size = event.get_size
x = frame_size.x - 10
y = fr...
2007 Dec 28
4
static box sizing problems
...w( HORIZONTAL )
txt = StaticText.new (self, -1, "Text Left")
lr_sizer.add(txt, 1, EXPAND | ALL, 4)
static_box = StaticBox.new(self, -1, "Static Box")
right_sizer = StaticBoxSizer.new( static_box, VERTICAL )
lr_sizer.add(right_sizer, 0, EXPAND | ALL, 4)
set_sizer(lr_sizer)
layout()
This code runs and gives almost what I want. The text appears on the left
and the static box on the right. However, the static box is a tiny sliver.
What I want is to fix the width of the static box. So I try adding a size
argument to the static box constructor:
stat...