@ -96,4 +96,22 @@ do_test(0, 0);
|
||||
cmd 'resize set 100 ppt 0 px';
|
||||
do_test(1333, 0);
|
||||
|
||||
################################################################################
|
||||
# Use 'width' and 'height' keywords.
|
||||
# See issue: #3275.
|
||||
################################################################################
|
||||
|
||||
cmd 'resize set width 200 px';
|
||||
do_test(200, 0);
|
||||
|
||||
cmd 'resize set height 200 px';
|
||||
do_test(0, 200);
|
||||
|
||||
cmd 'resize set width 300 px height 300 px';
|
||||
do_test(300, 300);
|
||||
|
||||
# ppt + keyword used only for height
|
||||
cmd 'resize set 100 ppt height 100 px';
|
||||
do_test(1333, 100);
|
||||
|
||||
done_testing;
|
||||
|
@ -39,6 +39,14 @@ my ($nodes, $focus) = get_ws_content($tmp);
|
||||
cmp_float($nodes->[0]->{percent}, 0.25, 'left window got only 25%');
|
||||
cmp_float($nodes->[1]->{percent}, 0.75, 'right window got 75%');
|
||||
|
||||
# Same but use the 'width' keyword.
|
||||
cmd 'resize set width 80 ppt';
|
||||
|
||||
($nodes, $focus) = get_ws_content($tmp);
|
||||
|
||||
cmp_float($nodes->[0]->{percent}, 0.20, 'left window got 20%');
|
||||
cmp_float($nodes->[1]->{percent}, 0.80, 'right window got 80%');
|
||||
|
||||
############################################################
|
||||
# resize vertically
|
||||
############################################################
|
||||
@ -61,6 +69,13 @@ my ($nodes, $focus) = get_ws_content($tmp);
|
||||
cmp_float($nodes->[0]->{percent}, 0.25, 'top window got only 25%');
|
||||
cmp_float($nodes->[1]->{percent}, 0.75, 'bottom window got 75%');
|
||||
|
||||
# Same but use the 'height' keyword.
|
||||
cmd 'resize set height 80 ppt';
|
||||
|
||||
($nodes, $focus) = get_ws_content($tmp);
|
||||
|
||||
cmp_float($nodes->[0]->{percent}, 0.20, 'top window got 20%');
|
||||
cmp_float($nodes->[1]->{percent}, 0.80, 'bottom window got 80%');
|
||||
|
||||
############################################################
|
||||
# resize horizontally and vertically
|
||||
|
Reference in New Issue
Block a user