SlideShare a Scribd company logo
Flamingo: Bringing the
Ribbon Component to
Swing
Kirill Grouchnikov
Amdocs
Agenda
>   What is a ribbon?
>   Swing ribbon implementation
>   Swing ribbon structure
       Basic terminology
       Command buttons
       Ribbon bands
       Ribbon tasks
       Miscellaneous
>   Where to next?

                                  2
What is a ribbon?




                    3
Ribbon demo

              4
http://blogs.msdn.com/jensenh




                                5
Ribbon availability
>   Available for WinForms, Win32, WPF, Silverlight
>   Third-party vendors




>   Microsoft – WPF 3.5, Windows 7 (scenic ribbon)




                                                      6
Ribbon for Swing applications
              Metal             Looks Plastic XP




              Nimbus                     A03




                                                   7
Ribbon for Swing applications
         Office Blue 2007       Office Silver 2007




                 Creme                   Nebula




         Raven Graphite                  Autumn




                                                     8
Ribbon for Swing applications
           Black Moon           Orange Metallic




            Blue Moon           Mauve Metallic




             Blue Ice             Sky Metallic




                                                  9
Ribbon for Swing applications




   http://flamingo.dev.java.net




                                  10
Basic ribbon terminology

Application menu button                          Contextual ribbon task group
                                   Ribbon task
              Taskbar panel                                                                Help button
                                                                  Contextual ribbon task




                          Ribbon gallery
         Ribbon band                                          Ribbon band expand button




                                                                                                         11
Basic hierarchy
>   Ribbon
                                               Ribbon task
       Contains tasks
           Containing bands

>   JRibbon
       RibbonTask
           AbstractRibbonBand   Ribbon band




                                                             12
Basic building block




             Command buttons




                               13
Command buttons
>   AbstractCommandButton
       JCommandButton
       JCommandToggleButton




                               14
Command
buttons demo

               15
Display state

AbstractCommandButton.setDisplayState(
  CommandButtonDisplayState)



                  BIG     TILE      MEDIUM


                                    SMALL




                                             16
Action and popup areas
JCommandButton.setCommandButtonKind(CommandButtonKind)



   ACTION_ONLY   ACTION_AND_POPUP   ACTION_AND_POPUP   POPUP_ONLY
                   _MAIN_ACTION        _MAIN_POPUP




 ActionButtonModel AbstractCommandButton.getActionModel()
 PopupButtonModel JCommandButton.getPopupModel()




                                                                    17
Simple popups
JCommandButton.setPopupCallback(PopupPanelCallback)
             JCommandButton button = ...;
             button.setPopupCallback(new PopupPanelCallback() {
               public JPopupPanel getPopupPanel(
                            JCommandButton commandButton) {
                    JCommandPopupMenu menu =
                            new JCommandPopupMenu();
                    menu.addMenuButton(...);
                    menu.addMenuSeparator();
                    ...
                    return menu;
               }
             });




                                                                  18
Command button strips
JCommandButtonStrip

         HORIZONTAL     VERTICAL




                                   19
Command button panels
JCommandButtonPanel

        ROW_FILL        COLUMN_FILL




                                      20
Rich popups
              JCommandButton button = ...;
              button.setPopupCallback(new PopupPanelCallback() {
                public JPopupPanel getPopupPanel(
                             JCommandButton commandButton) {
                     JCommandButtonPanel panel =
                             new JCommandButtonPanel(...);
                     panel.addButtonGroup(...);
                     panel.addButtonToGroup(...);
                     ...
                     JCommandPopupMenu menu =
                             new JCommandPopupMenu(panel,
                                    maxColumns, maxRows);
                     ...
                     return menu;
                }
              });

                                                           21
Bands / tasks
   demo

                22
Ribbon bands



         Ribbon band   Ribbon band   Flow ribbon band   Ribbon band




>   AbstractRibbonBand
       JRibbonBand
       JFlowRibbonBand



                                                                      23
Flow ribbon bands
JFlowRibbonBand

Adding content:
  addFlowComponent(JComponent)




      Two row flowing       Three row flowing   Collapsed
         content                content




                                                            24
Regular ribbon bands
JRibbonBand

Can host:
> command buttons
> wrapped core / 3rd party components
> ribbon galleries




                                        25
Hosting command buttons
        JRibbonBand clipboardBand = new JRibbonBand(
          “Clipboard”, ...);

        JCommandButton pasteButton = new JCommandButton(
          “Paste”, pasteIcon);
        pasteButton.setCommandButtonKind(
          CommandButtonKind.ACTION_AND_POPUP_MAIN_ACTION);
        pasteButton.setPopupCallback(...);
        clipboardBand.addCommandButton(pasteButton,
          RibbonElementPriority.TOP);

        ...

        clipboardBand.addCommandButton(cutButton,
          RibbonElementPriority.MEDIUM);



                                                             26
Hosting core and 3rd party controls



        Simple wrapping                      Wrapping with icon
                                                and caption




                          Wrapped components
                          spanning multiple rows


                                                                  27
Ribbon galleries
  Hosted gallery   Expanded gallery   Expanded gallery
                   shown in a popup    scrolled down




  Hosted gallery
  scrolled down




                                                         28
Groups in ribbon bands

         Two unnamed
           groups with
      command buttons


         Three unnamed
             groups with
       command buttons


      Two named groups
       with wrapped core
             components




                           29
Ribbon tasks
       Ribbon task           Ribbon task          Ribbon task
                  Ribbon task          Ribbon task




new RibbonTask(title,
  AbstractRibbonBand... bands)

JRibbon.addTask(RibbonTask)

                                                                30
Contextual task groups
               Contextual ribbon task group               Contextual ribbon task group

                                       Contextual ribbon task




                                   Selected contextual ribbon task




                                                                                     31
Menu button /
taskbar demo

                32
Application menu button
Application menu button




                           33
Application menu


     Primary                                Secondary
  menu group                                menu group




                               Footer
 JRibbon.setApplicationMenu(RibbonApplicationMenu)

                                                         34
Taskbar panel

     Taskbar panel




JRibbon.addTaskbarComponent(Component)




                                         35
Tooltips / key
 tips demo

                 36
Rich tooltips


        Tooltip for the
          action area




                          Displayed below
                          the ribbon


        Tooltip for the
          popup area




                                            37
Rich tooltips


    Tooltip for wrapped
      core component
                           Multiple
                           paragraphs



     Tooltip for taskbar
                           Displayed below
            component
                           the taskbar




                                             38
Rich tooltips


       Tooltip for
application menu
           button


                     Footer section
                     and images




                                      39
Key tips

  Press Alt or         Showing key           Showing key tips
  F10 for the           tips of the           of the selected
   top chain           selected task               button

                 P                     V

                 Esc                   Esc




                                                                40
Resizing /
minimized
  demo
             41
Ribbon resizing




                  42
Ribbon resizing, collapsing and scrolling
                   Scrolling tasks   Scrolling bands




  Expanding the
collapsed ribbon
            band


                                                       43
Minimized mode



                 JRibbon.setMinimized(true)
                 User double-clicking a task button
                 User pressing Ctrl+F1



                 User clicking a task button




                                                      44
Big features recap
>   Ribbon regular and flow bands
>   Ribbon galleries
>   Ribbon tasks and contextual task groups
>   Application menu button and taskbar panel
>   Resizing, collapsing and scrolling
>   Rich tooltips and key tips
>   Minimized mode



                                                45
Under the hood
>   Visual consistency across LAFs
    >   org.jvnet.flamingo.common.ui.BasicCommandButtonUI.paintB
        uttonBackground
>   Key tips
    >   org.jvnet.flamingo.ribbon.JRibbonFrame.KeyTipLayer
>   Placing content in the title pane
    >   org.jvnet.substance.flamingo.ribbon.ui.SubstanceRibbonFr
        ameTitlePane
>   More in the code…



                                                               46
What is missing - small
>   Hosting small buttons in galleries
>   Resizing popup panels
>   Navigating with keyboard (arrows, tabs)
>   Dragging controls to the taskbar panel
>   Hosting taskbar panel below the ribbon




                                              47
What is missing - medium
>   Right-to-left support
>   High DPI support




                            48
Potentially useful
>   XML-driven ribbon content
>   SWT version
>   World domination




                                49
Try it now!




    http://flamingo.dev.java.net


                                   50
Kirill Grouchnikov
kirillcool@yahoo.com
http://flamingo.dev.java.net
http://www.pushing-pixels.org




                                51

More Related Content

What's hot

Escaping The Jar hell with Jigsaw Layers
Escaping The Jar hell with Jigsaw LayersEscaping The Jar hell with Jigsaw Layers
Escaping The Jar hell with Jigsaw Layers
Nikita Lipsky
 
コードレビューを文化にするまでの取り組み.pdf
コードレビューを文化にするまでの取り組み.pdfコードレビューを文化にするまでの取り組み.pdf
コードレビューを文化にするまでの取り組み.pdf
ssuser5ddba11
 
Spring native について
Spring native についてSpring native について
Spring native について
Takamasa Mitsuji
 
GoF デザインパターン 2009
GoF デザインパターン 2009GoF デザインパターン 2009
GoF デザインパターン 2009
miwarin
 
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
Hikaru Ito
 
Akkaとは。アクターモデル とは。
Akkaとは。アクターモデル とは。Akkaとは。アクターモデル とは。
Akkaとは。アクターモデル とは。
Kenjiro Kubota
 
Fiberの使いどころ
Fiberの使いどころFiberの使いどころ
Fiberの使いどころ
Tomoya Kawanishi
 
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜 ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
toshihiro ichitani
 
【講演資料】ハード+ソフトの協調アジャイル開発
【講演資料】ハード+ソフトの協調アジャイル開発【講演資料】ハード+ソフトの協調アジャイル開発
【講演資料】ハード+ソフトの協調アジャイル開発
Hiroaki Matsunaga
 
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
Koichiro Matsuoka
 
Java 9で進化する診断ツール
Java 9で進化する診断ツールJava 9で進化する診断ツール
Java 9で進化する診断ツール
Yasumasa Suenaga
 
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
Shinji Takao
 
PowerApps JSONの使い道
PowerApps JSONの使い道PowerApps JSONの使い道
PowerApps JSONの使い道
Nagao Hiroaki
 
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
Y Watanabe
 
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージ
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージHBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージ
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージLINE Corporation
 
Amazon Redshiftによるリアルタイム分析サービスの構築
Amazon Redshiftによるリアルタイム分析サービスの構築Amazon Redshiftによるリアルタイム分析サービスの構築
Amazon Redshiftによるリアルタイム分析サービスの構築
Minero Aoki
 
開発チーム管理で役立ったVSCode拡張機能
開発チーム管理で役立ったVSCode拡張機能開発チーム管理で役立ったVSCode拡張機能
開発チーム管理で役立ったVSCode拡張機能
Masaki Suzuki
 
ラズピコでLチカ
ラズピコでLチカラズピコでLチカ
ラズピコでLチカ
iPride Co., Ltd.
 
最近のやられアプリを試してみた
最近のやられアプリを試してみた最近のやられアプリを試してみた
最近のやられアプリを試してみた
zaki4649
 

What's hot (20)

Escaping The Jar hell with Jigsaw Layers
Escaping The Jar hell with Jigsaw LayersEscaping The Jar hell with Jigsaw Layers
Escaping The Jar hell with Jigsaw Layers
 
コードレビューを文化にするまでの取り組み.pdf
コードレビューを文化にするまでの取り組み.pdfコードレビューを文化にするまでの取り組み.pdf
コードレビューを文化にするまでの取り組み.pdf
 
Spring native について
Spring native についてSpring native について
Spring native について
 
GoF デザインパターン 2009
GoF デザインパターン 2009GoF デザインパターン 2009
GoF デザインパターン 2009
 
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
Cordovaで作る!センサと超小型BLEモジュールを用いた簡単IoTアプリ開発
 
Akkaとは。アクターモデル とは。
Akkaとは。アクターモデル とは。Akkaとは。アクターモデル とは。
Akkaとは。アクターモデル とは。
 
Di入門
Di入門Di入門
Di入門
 
Fiberの使いどころ
Fiberの使いどころFiberの使いどころ
Fiberの使いどころ
 
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜 ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
ともに考え、ともにつくる 〜リーン・ジャーニー・スタイル〜
 
【講演資料】ハード+ソフトの協調アジャイル開発
【講演資料】ハード+ソフトの協調アジャイル開発【講演資料】ハード+ソフトの協調アジャイル開発
【講演資料】ハード+ソフトの協調アジャイル開発
 
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
Aws Dev Day2021 「ドメイン駆動設計のマイクロサービスへの活用とデベロッパーに求められるスキル」参考資料(松岡パート)
 
Java 9で進化する診断ツール
Java 9で進化する診断ツールJava 9で進化する診断ツール
Java 9で進化する診断ツール
 
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
GraalVM を普通の Java VM として使う ~クラウドベンチマークなどでの比較~
 
PowerApps JSONの使い道
PowerApps JSONの使い道PowerApps JSONの使い道
PowerApps JSONの使い道
 
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
jooqってなんて読むの? から始めるO/RマッパーとSpringBootの世界
 
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージ
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージHBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージ
HBaseとRedisを使った100億超/日メッセージを処理するLINEのストレージ
 
Amazon Redshiftによるリアルタイム分析サービスの構築
Amazon Redshiftによるリアルタイム分析サービスの構築Amazon Redshiftによるリアルタイム分析サービスの構築
Amazon Redshiftによるリアルタイム分析サービスの構築
 
開発チーム管理で役立ったVSCode拡張機能
開発チーム管理で役立ったVSCode拡張機能開発チーム管理で役立ったVSCode拡張機能
開発チーム管理で役立ったVSCode拡張機能
 
ラズピコでLチカ
ラズピコでLチカラズピコでLチカ
ラズピコでLチカ
 
最近のやられアプリを試してみた
最近のやられアプリを試してみた最近のやられアプリを試してみた
最近のやられアプリを試してみた
 

More from Kirill Grouchnikov

Responsive mobile design in practice
Responsive mobile design in practiceResponsive mobile design in practice
Responsive mobile design in practiceKirill Grouchnikov
 
Designing for the mobile form factor
Designing for the mobile form factorDesigning for the mobile form factor
Designing for the mobile form factor
Kirill Grouchnikov
 
Substance Java One 2007 Community Corner
Substance Java One 2007  Community  CornerSubstance Java One 2007  Community  Corner
Substance Java One 2007 Community Corner
Kirill Grouchnikov
 
Party of One
Party of OneParty of One
Party of One
Kirill Grouchnikov
 
Advanced Effects Oscon 2007
Advanced Effects   Oscon 2007Advanced Effects   Oscon 2007
Advanced Effects Oscon 2007
Kirill Grouchnikov
 
High DPI for desktop applications
High DPI for desktop applicationsHigh DPI for desktop applications
High DPI for desktop applications
Kirill Grouchnikov
 
On The Shoulders Of Giants
On The Shoulders Of GiantsOn The Shoulders Of Giants
On The Shoulders Of Giants
Kirill Grouchnikov
 

More from Kirill Grouchnikov (8)

Responsive mobile design in practice
Responsive mobile design in practiceResponsive mobile design in practice
Responsive mobile design in practice
 
Responsive mobile design
Responsive mobile designResponsive mobile design
Responsive mobile design
 
Designing for the mobile form factor
Designing for the mobile form factorDesigning for the mobile form factor
Designing for the mobile form factor
 
Substance Java One 2007 Community Corner
Substance Java One 2007  Community  CornerSubstance Java One 2007  Community  Corner
Substance Java One 2007 Community Corner
 
Party of One
Party of OneParty of One
Party of One
 
Advanced Effects Oscon 2007
Advanced Effects   Oscon 2007Advanced Effects   Oscon 2007
Advanced Effects Oscon 2007
 
High DPI for desktop applications
High DPI for desktop applicationsHigh DPI for desktop applications
High DPI for desktop applications
 
On The Shoulders Of Giants
On The Shoulders Of GiantsOn The Shoulders Of Giants
On The Shoulders Of Giants
 

Recently uploaded

Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Product School
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
DianaGray10
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
DianaGray10
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 

Recently uploaded (20)

Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 

Flamingo Ribbon component

  • 1. Flamingo: Bringing the Ribbon Component to Swing Kirill Grouchnikov Amdocs
  • 2. Agenda > What is a ribbon? > Swing ribbon implementation > Swing ribbon structure  Basic terminology  Command buttons  Ribbon bands  Ribbon tasks  Miscellaneous > Where to next? 2
  • 3. What is a ribbon? 3
  • 6. Ribbon availability > Available for WinForms, Win32, WPF, Silverlight > Third-party vendors > Microsoft – WPF 3.5, Windows 7 (scenic ribbon) 6
  • 7. Ribbon for Swing applications Metal Looks Plastic XP Nimbus A03 7
  • 8. Ribbon for Swing applications Office Blue 2007 Office Silver 2007 Creme Nebula Raven Graphite Autumn 8
  • 9. Ribbon for Swing applications Black Moon Orange Metallic Blue Moon Mauve Metallic Blue Ice Sky Metallic 9
  • 10. Ribbon for Swing applications http://flamingo.dev.java.net 10
  • 11. Basic ribbon terminology Application menu button Contextual ribbon task group Ribbon task Taskbar panel Help button Contextual ribbon task Ribbon gallery Ribbon band Ribbon band expand button 11
  • 12. Basic hierarchy > Ribbon Ribbon task  Contains tasks  Containing bands > JRibbon  RibbonTask  AbstractRibbonBand Ribbon band 12
  • 13. Basic building block Command buttons 13
  • 14. Command buttons > AbstractCommandButton  JCommandButton  JCommandToggleButton 14
  • 16. Display state AbstractCommandButton.setDisplayState( CommandButtonDisplayState) BIG TILE MEDIUM SMALL 16
  • 17. Action and popup areas JCommandButton.setCommandButtonKind(CommandButtonKind) ACTION_ONLY ACTION_AND_POPUP ACTION_AND_POPUP POPUP_ONLY _MAIN_ACTION _MAIN_POPUP ActionButtonModel AbstractCommandButton.getActionModel() PopupButtonModel JCommandButton.getPopupModel() 17
  • 18. Simple popups JCommandButton.setPopupCallback(PopupPanelCallback) JCommandButton button = ...; button.setPopupCallback(new PopupPanelCallback() { public JPopupPanel getPopupPanel( JCommandButton commandButton) { JCommandPopupMenu menu = new JCommandPopupMenu(); menu.addMenuButton(...); menu.addMenuSeparator(); ... return menu; } }); 18
  • 20. Command button panels JCommandButtonPanel ROW_FILL COLUMN_FILL 20
  • 21. Rich popups JCommandButton button = ...; button.setPopupCallback(new PopupPanelCallback() { public JPopupPanel getPopupPanel( JCommandButton commandButton) { JCommandButtonPanel panel = new JCommandButtonPanel(...); panel.addButtonGroup(...); panel.addButtonToGroup(...); ... JCommandPopupMenu menu = new JCommandPopupMenu(panel, maxColumns, maxRows); ... return menu; } }); 21
  • 22. Bands / tasks demo 22
  • 23. Ribbon bands Ribbon band Ribbon band Flow ribbon band Ribbon band > AbstractRibbonBand  JRibbonBand  JFlowRibbonBand 23
  • 24. Flow ribbon bands JFlowRibbonBand Adding content: addFlowComponent(JComponent) Two row flowing Three row flowing Collapsed content content 24
  • 25. Regular ribbon bands JRibbonBand Can host: > command buttons > wrapped core / 3rd party components > ribbon galleries 25
  • 26. Hosting command buttons JRibbonBand clipboardBand = new JRibbonBand( “Clipboard”, ...); JCommandButton pasteButton = new JCommandButton( “Paste”, pasteIcon); pasteButton.setCommandButtonKind( CommandButtonKind.ACTION_AND_POPUP_MAIN_ACTION); pasteButton.setPopupCallback(...); clipboardBand.addCommandButton(pasteButton, RibbonElementPriority.TOP); ... clipboardBand.addCommandButton(cutButton, RibbonElementPriority.MEDIUM); 26
  • 27. Hosting core and 3rd party controls Simple wrapping Wrapping with icon and caption Wrapped components spanning multiple rows 27
  • 28. Ribbon galleries Hosted gallery Expanded gallery Expanded gallery shown in a popup scrolled down Hosted gallery scrolled down 28
  • 29. Groups in ribbon bands Two unnamed groups with command buttons Three unnamed groups with command buttons Two named groups with wrapped core components 29
  • 30. Ribbon tasks Ribbon task Ribbon task Ribbon task Ribbon task Ribbon task new RibbonTask(title, AbstractRibbonBand... bands) JRibbon.addTask(RibbonTask) 30
  • 31. Contextual task groups Contextual ribbon task group Contextual ribbon task group Contextual ribbon task Selected contextual ribbon task 31
  • 34. Application menu Primary Secondary menu group menu group Footer JRibbon.setApplicationMenu(RibbonApplicationMenu) 34
  • 35. Taskbar panel Taskbar panel JRibbon.addTaskbarComponent(Component) 35
  • 36. Tooltips / key tips demo 36
  • 37. Rich tooltips Tooltip for the action area Displayed below the ribbon Tooltip for the popup area 37
  • 38. Rich tooltips Tooltip for wrapped core component Multiple paragraphs Tooltip for taskbar Displayed below component the taskbar 38
  • 39. Rich tooltips Tooltip for application menu button Footer section and images 39
  • 40. Key tips Press Alt or Showing key Showing key tips F10 for the tips of the of the selected top chain selected task button P V Esc Esc 40
  • 43. Ribbon resizing, collapsing and scrolling Scrolling tasks Scrolling bands Expanding the collapsed ribbon band 43
  • 44. Minimized mode JRibbon.setMinimized(true) User double-clicking a task button User pressing Ctrl+F1 User clicking a task button 44
  • 45. Big features recap > Ribbon regular and flow bands > Ribbon galleries > Ribbon tasks and contextual task groups > Application menu button and taskbar panel > Resizing, collapsing and scrolling > Rich tooltips and key tips > Minimized mode 45
  • 46. Under the hood > Visual consistency across LAFs > org.jvnet.flamingo.common.ui.BasicCommandButtonUI.paintB uttonBackground > Key tips > org.jvnet.flamingo.ribbon.JRibbonFrame.KeyTipLayer > Placing content in the title pane > org.jvnet.substance.flamingo.ribbon.ui.SubstanceRibbonFr ameTitlePane > More in the code… 46
  • 47. What is missing - small > Hosting small buttons in galleries > Resizing popup panels > Navigating with keyboard (arrows, tabs) > Dragging controls to the taskbar panel > Hosting taskbar panel below the ribbon 47
  • 48. What is missing - medium > Right-to-left support > High DPI support 48
  • 49. Potentially useful > XML-driven ribbon content > SWT version > World domination 49
  • 50. Try it now! http://flamingo.dev.java.net 50