mirror of
https://github.com/KAMKEEL/CustomNPC-Plus-API.git
synced 2026-11-17 22:45:12 +00:00
GUI Api
This commit is contained in:
1 parent
8c2c226d34
commit
a876b4d191
9 files changed
+933
-193
No files matched your search
@@ -1,21 +1,75 @@
|
||||
package noppes.npcs.api.gui;
|
||||
|
||||
public interface ILabel extends ICustomGuiComponent {
|
||||
String getText();
|
||||
|
||||
ILabel setText(String text);
|
||||
|
||||
int getWidth();
|
||||
|
||||
int getHeight();
|
||||
|
||||
ILabel setSize(int width, int height);
|
||||
|
||||
float getScale();
|
||||
|
||||
ILabel setScale(float scale);
|
||||
|
||||
boolean getShadow();
|
||||
|
||||
void setShadow(boolean shadow);
|
||||
}
|
||||
package noppes.npcs.api.gui;
|
||||
|
||||
/**
|
||||
* Represents a text label component in a custom GUI.
|
||||
* Provides methods to get or set text, size, scale, and shadow properties.
|
||||
*/
|
||||
public interface ILabel extends ICustomGuiComponent {
|
||||
|
||||
/**
|
||||
* Returns the text of the label.
|
||||
*
|
||||
* @return the label text.
|
||||
*/
|
||||
String getText();
|
||||
|
||||
/**
|
||||
* Sets the label text.
|
||||
*
|
||||
* @param text the new text.
|
||||
* @return this label instance.
|
||||
*/
|
||||
ILabel setText(String text);
|
||||
|
||||
/**
|
||||
* Returns the label's width.
|
||||
*
|
||||
* @return the width in pixels.
|
||||
*/
|
||||
int getWidth();
|
||||
|
||||
/**
|
||||
* Returns the label's height.
|
||||
*
|
||||
* @return the height in pixels.
|
||||
*/
|
||||
int getHeight();
|
||||
|
||||
/**
|
||||
* Sets the size of the label.
|
||||
*
|
||||
* @param width the new width.
|
||||
* @param height the new height.
|
||||
* @return this label instance.
|
||||
*/
|
||||
ILabel setSize(int width, int height);
|
||||
|
||||
/**
|
||||
* Returns the scale factor of the label.
|
||||
*
|
||||
* @return the scale.
|
||||
*/
|
||||
float getScale();
|
||||
|
||||
/**
|
||||
* Sets the scale factor of the label.
|
||||
*
|
||||
* @param scale the new scale.
|
||||
* @return this label instance.
|
||||
*/
|
||||
ILabel setScale(float scale);
|
||||
|
||||
/**
|
||||
* Returns whether the label text is rendered with a shadow.
|
||||
*
|
||||
* @return true if shadow is enabled; false otherwise.
|
||||
*/
|
||||
boolean getShadow();
|
||||
|
||||
/**
|
||||
* Sets whether the label text should be rendered with a shadow.
|
||||
*
|
||||
* @param shadow true to enable shadow.
|
||||
*/
|
||||
void setShadow(boolean shadow);
|
||||
}
|
||||
Reference in new issue
Block a user