in reply to Re^2: Invisible Prima::Radio
in thread Invisible Prima::Radio

FWIW, origin is mentioned in some places :) http://search.cpan.org/grep?cpanid=KARASIK&release=Prima-1.41&string=origin&i=1&n=1&C=9

If I use VB this is what it spits out

package Form1Window; use Prima; use Prima::Classes; use vars qw(@ISA); @ISA = qw(Prima::MainWindow); use Prima::Buttons; sub profile_default { my $def = $_[ 0]-> SUPER::profile_default; my %prf = ( sizeDontCare => 0, origin => [ 362, 145], name => 'Form1', originDontCare => 0, size => [ 401, 239], width => 401, height => 239, left => 362, bottom => 145, designScale => [ 5, 13], ); @$def{keys %prf} = values %prf; return $def; } sub init { my $self = shift; my %instances = map {$_ => {}} qw(); my %profile = $self-> SUPER::init(@_); my %names = ( q(Form1) => $self); $self-> lock; $names{GroupBox1} = $names{Form1}-> insert( qq(Prima::GroupBox) => + name => 'GroupBox1', origin => [ 20, 104], size => [ 148, 132], ); $names{Radio1} = $names{GroupBox1}-> insert( qq(Prima::Radio) => name => 'Radio1', origin => [ 12, 76], size => [ 100, 36], ); $names{Radio2} = $names{GroupBox1}-> insert( qq(Prima::Radio) => origin => [ 12, 36], name => 'Radio2', size => [ 100, 36], ); $self-> unlock; return %profile; } package Form1Auto; use Prima::Application; Form1Window-> create; run Prima;

Messing with the VB options I come upon  geometry => gt::Pack, which when added to your radios makes them show up

Prima::tutorial talks about "pack", as does https://metacpan.org/pod/Prima::Widget#Geometry-managers and Prima::Widget::pack

geometry/sizers/packers/layout is standard GUI vocabulary for this type of thing

Replies are listed 'Best First'.
Re^4: Invisible Prima::Radio
by over2sd (Beadle) on Feb 18, 2015 at 04:06 UTC

    Thank you for the info.

    I'd been using pack with other things, but I guess I thought radio buttons were one of those things you'd want to always work pretty much the same way by default, so I didn't think to use pack for them.

    I make so many silly mistakes.