Class BoardEditorTooltip

java.lang.Object
megamek.client.ui.swing.boardview.BoardEditorTooltip
All Implemented Interfaces:
BoardViewTooltipProvider

public class BoardEditorTooltip extends Object implements BoardViewTooltipProvider
This class is a BoardViewTooltipProvider that is tailored to the Board Editor and lists detailed terrain info about the hovered hex.
  • Constructor Details

    • BoardEditorTooltip

      public BoardEditorTooltip(IGame game, IBoardView boardView)
  • Method Details

    • getTooltip

      public String getTooltip(Point point, Coords movementTarget)
      Description copied from interface: BoardViewTooltipProvider
      Returns a String that is displayed as the tooltip for the given point in the BoardView's drawing area. The String may be an HTML string. It is passed to Swing's TooltipManager without further modification, i.e. if it is an HTML string all tags must already be present. The given movementTarget coordinates may be used to display information about another hex or field in that BoardView.
      Specified by:
      getTooltip in interface BoardViewTooltipProvider
      Parameters:
      point - The point in the BoardView's drawing area as returned e.g. with a MouseEvent
      movementTarget - Another coordinate to display additional information about
      Returns:
      The tooltip to display