如果對顯示框使用 << 複製圖片,例如 Vlistbox,生成的圖像將在底部被錯誤截斷,多個顯示框垂直堆疊在 Vlistbox 中。這看起來類似於 <
問題:圖像在底部截斷(db1、db2 是某種顯示框)
vlb = V List Box( db1, db2 ) << copy picture;
Fix:vlb = V List Box( db1, db2 );
nw = New Window( "nw", vlb );
nw << copy picture;
nw << close window;
因此,如果您將其包裝在一個窗口中,則圖像會正確複製而不會被截斷。也許其他展示盒也可以。
打碟機
我不確定如何重現您的問題,您能否舉例說明出現問題的具體展示框?在下面的腳本中,我將幾個盒子堆疊在一起,從帶有和不帶有窗口的 vlb 複製的圖像是相同的。請注意,我確實對您的示例進行了一些語法更改:
Names default to here(1);
dt = Open( "$Sample_data/big class.jmp" );
// make boxes that are bigger than the monitor when stacked, first two fixed sizse
db1 = spacer box( Size( 1000, 1000), Color( blue ) );
db2 = spacer box( Size( 1000, 1000), Color( red ) );
// third one in an outline box
db3 = report( Graph Builder(
Size( 800, 800 ),
Show Control Panel( 0 ),
Variables( X( :height ), Y( :weight ) ),
Elements( Points( X, Y, Legend( 2 ) ), Smoother( X, Y, Legend( 3 ) ) )
) );
//and last one wraps the third one in a fixed-size box
db4 = Scroll Box( Size( 1000, 1000), db3 );
// splitting your line into two, that way vlb is defined as the list box
// and not the result of copy picture
vlb = V List Box( db1, db2, db3, db4 );
// This gives a blue square on top of a red one (Fig 1):
vlb << copy picture;
// Not sure what is happening here, you haven't defined a 'Fix'namespace..
// Fix:vlb = V List Box( db1, db2 );
//In new window, it looks the same with two squares (Fig 2):
nw = New Window( "nw", vlb );
nw << copy picture;
nw << close window;
這是並排的兩個圖像:
