NTBalloonPopup
@interface NTBalloonPopup : NTPopup
A highly configurable popup implementation that allows the user to specify a title, description, colors, images, font sizes etc.
-
Constructs a BalloonPopup object with the specified style and attaches it to a billboard element. If an empty string is passed for the title, it will not be drawn. The same applies to the description.
Declaration
Objective-C
- (id)initWithBaseBillboard:(NTBillboard *)baseBillboard style:(NTBalloonPopupStyle *)style title:(NSString *)title desc:(NSString *)desc;Parameters
baseBillboardThe billboard this balloon popup will be attached to.
styleThe style that defines what this balloon popup looks like.
titleThe text this balloon popup will display.
descThe description this balloon popup will display.
-
Constructs a BalloonPopup object from a geometry object and a style. If an empty string is passed for the title, it will not be drawn. The same applies to the description.
Declaration
Objective-C
- (id)initWithGeometry:(NTGeometry *)geometry style:(NTBalloonPopupStyle *)style title:(NSString *)title desc:(NSString *)desc;Parameters
geometryThe geometry object that defines the location of this balloon popup.
styleThe style that defines what this balloon popup looks like.
titleThe text this balloon popup will display.
descThe description this balloon popup will display.
-
Constructs a BalloonPopup object from a map position and a style. If an empty string is passed for the title, it will not be drawn. The same applies to the description.
Declaration
Objective-C
- (id)initWithPos:(NTMapPos *)pos style:(NTBalloonPopupStyle *)style title:(NSString *)title desc:(NSString *)desc;Parameters
posThe map position that defines the location of this balloon popup.
styleThe style that defines what this balloon popup looks like.
titleThe text this balloon popup will display.
descThe description this balloon popup will display.
-
Returns the title of this balloon popup.
Declaration
Objective-C
- (NSString *)getTitle;Return Value
The title of this balloon popup.
-
Sets the title this balloon popup will display. If an empty string is passed the title will not be drawn.
Declaration
Objective-C
- (void)setTitle:(NSString *)title;Parameters
titleThe new title this balloon popup will display.
-
Returns the description of this balloon popup.
Declaration
Objective-C
- (NSString *)getDescription;Return Value
The description of this balloon popup.
-
Sets the description this balloon popup will display. If an empty string is passed the description will not be drawn.
Declaration
Objective-C
- (void)setDescription:(NSString *)desc;Parameters
descThe new description this balloon popup will display.
-
Returns the style of this balloon popup.
Declaration
Objective-C
- (NTBalloonPopupStyle *)getStyle;Return Value
The style that defines what this balloon popup looks like.
-
Sets the style for this balloon popup.
Declaration
Objective-C
- (void)setStyle:(NTBalloonPopupStyle *)style;Parameters
styleThe new style that defines what this balloon popup looks like.
-
Removes all buttons from the balloon popup.
Declaration
Objective-C
- (void)clearButtons; -
Adds a new button to the balloon popup. If the button is already added, the call is ignored.
Declaration
Objective-C
- (void)addButton:(NTBalloonPopupButton *)button;Parameters
buttonThe button object to add.
-
Replaces an old baloon popup button with a new button.
Declaration
Objective-C
- (void)replaceButton:(NTBalloonPopupButton *)oldButton newButton:(NTBalloonPopupButton *)newButton;Parameters
oldButtonThe old button to replace.
newButtonThe new button.
-
Removes a button from the balloon popup. If the button is not present, the call is ignored.
Declaration
Objective-C
- (void)removeButton:(NTBalloonPopupButton *)button;Parameters
buttonThe button object to remove.
-
Returns the balloon popup event listener.
Declaration
Objective-C
- (NTBalloonPopupEventListener *)getBalloonPopupEventListener;Return Value
The balloon popup event listener.
-
Sets the balloon popup event listener.
Declaration
Objective-C
- (void)setBalloonPopupEventListener: (NTBalloonPopupEventListener *)eventListener;Parameters
eventListenerThe balloon popup event listener.
-
Undocumented
Declaration
Objective-C
- (BOOL)processClick:(enum NTClickType)clickType clickPos:(NTMapPos *)clickPos elementClickPos:(NTScreenPos *)elementClickPos; -
Undocumented
Declaration
Objective-C
- (NTBitmap *)drawBitmap:(NTScreenPos *)anchorScreenPos screenWidth:(float)screenWidth screenHeight:(float)screenHeight dpToPX:(float)dpToPX; -
Undocumented
Declaration
Objective-C
-(void)dealloc;
View on GitHub
NTBalloonPopup Class Reference