當前位置: 首頁>>代碼示例>>Java>>正文


Java Browser.setVisible方法代碼示例

本文整理匯總了Java中org.eclipse.swt.browser.Browser.setVisible方法的典型用法代碼示例。如果您正苦於以下問題:Java Browser.setVisible方法的具體用法?Java Browser.setVisible怎麽用?Java Browser.setVisible使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.eclipse.swt.browser.Browser的用法示例。


在下文中一共展示了Browser.setVisible方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: widgetSelected

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public void widgetSelected( SelectionEvent e )
{
    if ( e.widget == btn )
    {
        int i = cbType.getSelectionIndex( );
        switch ( i )
        {
            case 0 :
                cm = InteractivityCharts.createSVGHSChart( );
                break;
            case 1 :
                cm = InteractivityCharts.createSTChart( );
                break;
            case 2 :
                cm = InteractivityCharts.createTVChart( );
                break;
            case 3 :
                cm = InteractivityCharts.createURChart( );
                break;
        }
        
        try
        {
            
            RunTimeContext rtc = new RunTimeContext( );
            rtc.setULocale( ULocale.getDefault( ) );

            idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
            Generator gr = Generator.instance( );
            Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
            gcs = gr.build( idr.getDisplayServer( ),
                    cm,
                    bo,
                    null,
                    rtc,
                    null );
            
            idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
            idr.setProperty( IDeviceRenderer.UPDATE_NOTIFIER,
                    new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

            gr.render( idr, gcs );
        }
        catch ( ChartException ce )
        {
            ce.printStackTrace( );
        }

        Shell shell = new Shell( display );
        shell.setSize( 620, 450 );
        shell.setLayout( new GridLayout( ) );

        Browser br = new Browser( shell, SWT.NONE );
        br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
        br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
        br.setVisible( true );

        shell.open( );
    }
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:61,代碼來源:SvgInteractivityViewer.java

示例2: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_117865_svg siv = new Regression_117865_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = showTooltip_AreaChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }

    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:56,代碼來源:Regression_145712_svg.java

示例3: widgetSelected

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public void widgetSelected( SelectionEvent e )
{
    if ( e.widget == btn )
    {
        int i = cbType.getSelectionIndex( );
        switch ( i )
        {
            case 0 :
                cm = BarChart( );
                break;
        }

        try
        {

            RunTimeContext rtc = new RunTimeContext( );
            rtc.setULocale( ULocale.getDefault( ) );

            idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
            Generator gr = Generator.instance( );
            GeneratedChartState gcs = null;
            Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
            gcs = gr.build(
                    idr.getDisplayServer( ),
                    cm,
                    bo,
                    null,
                    rtc,
                    null );

            idr
                    .setProperty(
                            IDeviceRenderer.FILE_IDENTIFIER,
                            "c:/test.svg" ); //$NON-NLS-1$
            idr.setProperty(
                    IDeviceRenderer.UPDATE_NOTIFIER,
                    new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

            gr.render( idr, gcs );
        }
        catch ( ChartException ce )
        {
            ce.printStackTrace( );
        }

        Shell shell = new Shell( display );
        shell.setSize( 620, 450 );
        shell.setLayout( new GridLayout( ) );

        Browser br = new Browser( shell, SWT.NONE );
        br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
        br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
        br.setVisible( true );

        shell.open( );
    }
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:58,代碼來源:Regression_117511_svg.java

示例4: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_132620_svg siv = new Regression_132620_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = toggleVisibility_BarChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }

    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:56,代碼來源:Regression_132620_svg.java

示例5: widgetSelected

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public void widgetSelected( SelectionEvent e )
{
    if ( e.widget == btn )
    {
        int i = cbType.getSelectionIndex( );
        switch ( i )
        {
            case 0 :
                cm = showTooltip_BarChart( );
                break;
        }

        try
        {

            RunTimeContext rtc = new RunTimeContext( );
            rtc.setULocale( ULocale.getDefault( ) );

            idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
            Generator gr = Generator.instance( );
            GeneratedChartState gcs = null;
            Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
            gcs = gr.build(
                    idr.getDisplayServer( ),
                    cm,
                    bo,
                    null,
                    rtc,
                    null );

            idr
                    .setProperty(
                            IDeviceRenderer.FILE_IDENTIFIER,
                            "c:/test.svg" ); //$NON-NLS-1$
            idr.setProperty(
                    IDeviceRenderer.UPDATE_NOTIFIER,
                    new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

            gr.render( idr, gcs );
        }
        catch ( ChartException ce )
        {
            ce.printStackTrace( );
        }

        Shell shell = new Shell( display );
        shell.setSize( 620, 450 );
        shell.setLayout( new GridLayout( ) );

        Browser br = new Browser( shell, SWT.NONE );
        br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
        br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
        br.setVisible( true );

        shell.open( );
    }
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:58,代碼來源:Regression_131260_svg.java

示例6: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_117865_svg siv = new Regression_117865_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = highlight_BarChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }

    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:56,代碼來源:Regression_145144_svg.java

示例7: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_117865_svg siv = new Regression_117865_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = toggleVisibility_PieChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }

    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:56,代碼來源:Regression_117865_svg.java

示例8: widgetSelected

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public void widgetSelected( SelectionEvent e )
{
    if ( e.widget == btn )
    {
        int i = cbType.getSelectionIndex( );
        switch ( i )
        {
            case 0 :
                cm = createMeterChart( );
                break;
        }

        try
        {

            RunTimeContext rtc = new RunTimeContext( );
            rtc.setULocale( ULocale.getDefault( ) );

            idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
            Generator gr = Generator.instance( );
            GeneratedChartState gcs = null;
            Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
            gcs = gr.build(
                    idr.getDisplayServer( ),
                    cm,
                    bo,
                    null,
                    rtc,
                    null );

            idr
                    .setProperty(
                            IDeviceRenderer.FILE_IDENTIFIER,
                            "c:/test.svg" ); //$NON-NLS-1$
            idr.setProperty(
                    IDeviceRenderer.UPDATE_NOTIFIER,
                    new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

            gr.render( idr, gcs );
        }
        catch ( ChartException ce )
        {
            ce.printStackTrace( );
        }

        Shell shell = new Shell( display );
        shell.setSize( 620, 450 );
        shell.setLayout( new GridLayout( ) );

        Browser br = new Browser( shell, SWT.NONE );
        br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
        br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
        br.setVisible( true );

        shell.open( );
    }
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:58,代碼來源:Regression_131658_svg.java

示例9: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_117876_svg siv = new Regression_117876_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = toggleVisibility_MeterChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }

    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:56,代碼來源:Regression_117876_svg.java

示例10: main

import org.eclipse.swt.browser.Browser; //導入方法依賴的package包/類
public static void main( String args[] )
{
    display = Display.getDefault( );
    Shell shell = new Shell( display );
    shell.setLocation( display.getClientArea( ).width / 2 - 110, display
            .getClientArea( ).height / 2 - 40 );
    shell.setSize( 620, 450 );
    shell.setLayout( new GridLayout( ) );

    Regression_128590_svg siv = new Regression_128590_svg( shell, SWT.NONE );
    GridData gd = new GridData( GridData.BEGINNING );
    gd.widthHint = 1;
    gd.heightHint = 1;
    siv.setLayoutData( gd );

    try
    {
        RunTimeContext rtc = new RunTimeContext( );
        rtc.setULocale( ULocale.getDefault( ) );

        IDeviceRenderer idr = null;
        Chart cm = showTooltip_BarChart( );

        idr = PluginSettings.instance( ).getDevice( "dv.SVG" ); //$NON-NLS-1$
        Generator gr = Generator.instance( );
        GeneratedChartState gcs = null;
        Bounds bo = BoundsImpl.create( 0, 0, 450, 300 );
        gcs = gr.build( idr.getDisplayServer( ), cm, bo, null, rtc, null );

        idr.setProperty( IDeviceRenderer.FILE_IDENTIFIER, "c:/test.svg" ); //$NON-NLS-1$
        idr.setProperty(
                IDeviceRenderer.UPDATE_NOTIFIER,
                new EmptyUpdateNotifier( cm, gcs.getChartModel( ) ) );

        gr.render( idr, gcs );
    }
    catch ( ChartException ce )
    {
        ce.printStackTrace( );
    }

    Browser br = new Browser( shell, SWT.NONE );
    br.setLayoutData( new GridData( GridData.FILL_BOTH ) );
    br.setUrl( "c:/test.svg" );//$NON-NLS-1$		
    br.setVisible( true );

    shell.open( );
    while ( !shell.isDisposed( ) )
    {
        if ( !display.readAndDispatch( ) )
            display.sleep( );
    }
    display.dispose( );
}
 
開發者ID:eclipse,項目名稱:birt,代碼行數:55,代碼來源:Regression_128590_svg.java


注:本文中的org.eclipse.swt.browser.Browser.setVisible方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。