Gridarta Editor
MapViewSettings.java
Go to the documentation of this file.
1 /*
2  * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games.
3  * Copyright (C) 2000-2023 The Gridarta Developers.
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program; if not, write to the Free Software Foundation, Inc.,
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18  */
19 
20 package net.sf.gridarta.model.mapviewsettings;
21 
23 import org.jetbrains.annotations.NotNull;
24 
30 public interface MapViewSettings {
31 
37 
43 
49  boolean isGridVisible();
50 
56  void setGridVisible(boolean gridVisible);
57 
63  boolean isLightVisible();
64 
70  void setLightVisible(boolean lightVisible);
71 
76  boolean isSmoothing();
77 
82  void setSmoothing(boolean smoothing);
83 
88  boolean isTileStretching();
89 
94  void setTileStretching(boolean tileStretching);
95 
101  boolean isDoubleFaces();
102 
107  void setDoubleFaces(boolean doubleFaces);
108 
115  boolean isAlphaType(int v);
116 
123  void setAlphaType(int v, boolean state);
124 
128  void clearAlpha();
129 
134  int getEditType();
135 
141  void unsetEditType(int editType);
142 
149  boolean isEditType(int editType);
150 
157  boolean isEditType(@NotNull BaseObject<?, ?, ?, ?> gameObject);
158 
164  boolean isEditTypeSet();
165 
170  void toggleEditType(int editType);
171 
176  boolean isAutojoin();
177 
182  void setAutojoin(boolean autojoin);
183 
184 }
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setTileStretching
void setTileStretching(boolean tileStretching)
Sets the tile-stretching setting.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isSmoothing
boolean isSmoothing()
Returns the smoothing setting.
net.sf.gridarta
Base package of all Gridarta classes.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setDoubleFaces
void setDoubleFaces(boolean doubleFaces)
Sets whether double faces should be drawn double height.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.getEditType
int getEditType()
Returns the currently set edit type.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isLightVisible
boolean isLightVisible()
Get the visibility of the light.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.clearAlpha
void clearAlpha()
Clear the transparency.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isGridVisible
boolean isGridVisible()
Get the visibility of the grid.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isAlphaType
boolean isAlphaType(int v)
Returns whether the specified edit type is to be shown transparent.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isTileStretching
boolean isTileStretching()
Returns the tile-stretching setting.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.addMapViewSettingsListener
void addMapViewSettingsListener(@NotNull MapViewSettingsListener listener)
Register a MapViewSettingsListener.
net.sf
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setGridVisible
void setGridVisible(boolean gridVisible)
Set the visibility of the grid.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isAutojoin
boolean isAutojoin()
Returns whether "autojoin" is enabled.
net.sf.gridarta.model.mapviewsettings.MapViewSettings
Container for settings that affect the rendering of maps.
Definition: MapViewSettings.java:30
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setAutojoin
void setAutojoin(boolean autojoin)
Sets the "autojoin" state.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.removeMapViewSettingsListener
void removeMapViewSettingsListener(@NotNull MapViewSettingsListener listener)
Unregister a MapViewSettingsListener.
net
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isEditType
boolean isEditType(int editType)
Get information on the current state of edit type.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.unsetEditType
void unsetEditType(int editType)
Set the map view to hide squares of the given type.
net.sf.gridarta.model.baseobject.BaseObject
Definition: BaseObject.java:34
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setSmoothing
void setSmoothing(boolean smoothing)
Sets the smoothing setting.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isDoubleFaces
boolean isDoubleFaces()
Get whether double faces are drawn double height.
net.sf.gridarta.model
net.sf.gridarta.model.baseobject
Definition: AbstractBaseObject.java:20
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setLightVisible
void setLightVisible(boolean lightVisible)
Set the visibility of the light.
net.sf.gridarta.model.mapviewsettings.MapViewSettingsListener
Interface for event listeners that are interested in changes on {}.
Definition: MapViewSettingsListener.java:31
net.sf.gridarta.model.mapviewsettings.MapViewSettings.toggleEditType
void toggleEditType(int editType)
Toggle an edit type.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.isEditTypeSet
boolean isEditTypeSet()
Returns whether a editType value is set so that not all squares are displayed.
net.sf.gridarta.model.mapviewsettings.MapViewSettings.setAlphaType
void setAlphaType(int v, boolean state)
Sets whether the specified edit type is to be shown transparent.