tron@2186: /* $Id$ */ tron@2186: truelight@0: #ifndef GUI_H truelight@0: #define GUI_H truelight@0: tron@2466: #include "station.h" darkvater@175: #include "window.h" truelight@4299: #include "string.h" darkvater@175: truelight@0: /* main_gui.c */ tron@1093: void SetupColorsAndInitialWindow(void); tron@1977: void CcPlaySound10(bool success, TileIndex tile, uint32 p1, uint32 p2); tron@1977: void CcBuildCanal(bool success, TileIndex tile, uint32 p1, uint32 p2); tron@1977: void CcTerraform(bool success, TileIndex tile, uint32 p1, uint32 p2); truelight@0: truelight@0: /* settings_gui.c */ tron@1093: void ShowGameOptions(void); tron@1093: void ShowGameDifficulty(void); tron@1093: void ShowPatchesSelection(void); miham@4211: void DrawArrowButtons(int x, int y, int ctab, byte state, bool clickable_left, bool clickable_right); truelight@0: truelight@0: /* graph_gui.c */ Darkvater@5291: extern const byte _cargo_colours[NUM_CARGO]; tron@1093: void ShowOperatingProfitGraph(void); tron@1093: void ShowIncomeGraph(void); tron@1093: void ShowDeliveredCargoGraph(void); tron@1093: void ShowPerformanceHistoryGraph(void); tron@1093: void ShowCompanyValueGraph(void); tron@1093: void ShowCargoPaymentRates(void); tron@1093: void ShowCompanyLeagueTable(void); tron@1093: void ShowPerformanceRatingDetail(void); truelight@0: truelight@0: /* news_gui.c */ tron@1093: void ShowLastNewsMessage(void); tron@1093: void ShowMessageOptions(void); tron@1093: void ShowMessageHistory(void); truelight@0: KUDr@5116: /* rail_gui.c */ tron@2520: void ShowBuildRailToolbar(RailType railtype, int button); tron@1977: void PlaceProc_BuyLand(TileIndex tile); KUDr@5116: void ReinitGuiAfterToggleElrail(bool disable); truelight@0: truelight@0: /* train_gui.c */ tron@2561: void ShowTrainViewWindow(const Vehicle *v); belugas@4171: void ShowOrdersWindow(const Vehicle *v); truelight@0: truelight@0: /* road_gui.c */ tron@1093: void ShowBuildRoadToolbar(void); tron@1093: void ShowBuildRoadScenToolbar(void); bjarni@4408: void ShowRoadVehViewWindow(const Vehicle *v); truelight@0: truelight@0: /* dock_gui.c */ tron@1093: void ShowBuildDocksToolbar(void); belugas@4171: void ShowShipViewWindow(const Vehicle *v); truelight@0: truelight@0: /* aircraft_gui.c */ tron@1093: void ShowBuildAirToolbar(void); truelight@0: truelight@0: /* terraform_gui.c */ Darkvater@1632: void ShowTerraformToolbar(void); Darkvater@1632: truelight@4300: /* tgp_gui.c */ truelight@4300: void ShowGenerateLandscape(void); truelight@4300: void ShowHeightmapLoad(void); truelight@4300: tron@1977: void PlaceProc_DemolishArea(TileIndex tile); tron@1977: void PlaceProc_LevelLand(TileIndex tile); belugas@4634: bool GUIPlaceProcDragXY(const WindowEvent *e); Darkvater@1632: Darkvater@1632: enum { // max 32 - 4 = 28 types Darkvater@1632: GUI_PlaceProc_DemolishArea = 0 << 4, Darkvater@1632: GUI_PlaceProc_LevelArea = 1 << 4, Darkvater@1632: GUI_PlaceProc_DesertArea = 2 << 4, Darkvater@1632: GUI_PlaceProc_WaterArea = 3 << 4, Darkvater@2615: GUI_PlaceProc_ConvertRailArea = 4 << 4, Darkvater@2615: GUI_PlaceProc_RockyArea = 5 << 4, Darkvater@1632: }; truelight@0: truelight@0: /* misc_gui.c */ tron@1093: void PlaceLandBlockInfo(void); tron@1093: void ShowAboutWindow(void); tron@1093: void ShowBuildTreesToolbar(void); tron@1093: void ShowBuildTreesScenToolbar(void); tron@1093: void ShowTownDirectory(void); tron@1093: void ShowIndustryDirectory(void); tron@1093: void ShowSubsidiesList(void); tron@2475: void ShowPlayerStations(PlayerID player); tron@2475: void ShowPlayerFinances(PlayerID player); tron@2475: void ShowPlayerCompany(PlayerID player); truelight@1575: void ShowSignList(void); truelight@0: truelight@0: void ShowEstimatedCostOrIncome(int32 cost, int x, int y); truelight@0: void ShowErrorMessage(StringID msg_1, StringID msg_2, int x, int y); truelight@0: Celestar@568: void DrawStationCoverageAreaText(int sx, int sy, uint mask,int rad); belugas@4171: void CheckRedrawStationCoverage(const Window *w); truelight@0: tron@1093: void ShowSmallMap(void); tron@1093: void ShowExtraViewPortWindow(void); truelight@0: void SetVScrollCount(Window *w, int num); bjarni@842: void SetVScroll2Count(Window *w, int num); truelight@0: void SetHScrollCount(Window *w, int num); truelight@0: tron@1093: void ShowCheatWindow(void); truelight@0: Darkvater@2887: void DrawEditBox(Window *w, querystr_d *string, int wid); Darkvater@2887: void HandleEditBox(Window *w, querystr_d *string, int wid); Darkvater@4909: int HandleEditBoxKey(Window *w, querystr_d *string, int wid, WindowEvent *we); Darkvater@1390: bool HandleCaret(Textbuf *tb); Darkvater@1390: Darkvater@1879: void DeleteTextBufferAll(Textbuf *tb); Darkvater@1390: bool DeleteTextBufferChar(Textbuf *tb, int delmode); peter1138@5108: bool InsertTextBufferChar(Textbuf *tb, uint32 key); Darkvater@1390: bool InsertTextBufferClipboard(Textbuf *tb); Darkvater@1390: bool MoveTextBufferPos(Textbuf *tb, int navmode); Darkvater@4948: void InitializeTextBuffer(Textbuf *tb, const char *buf, uint16 maxlength, uint16 maxwidth); Darkvater@1390: void UpdateTextBufferSize(Textbuf *tb); truelight@0: tron@1093: void BuildFileList(void); truelight@543: void SetFiosType(const byte fiostype); truelight@543: rubidium@4434: /* FIOS_TYPE_FILE, FIOS_TYPE_OLDFILE etc. different colours */ ludde@2261: extern const byte _fios_colors[]; truelight@0: truelight@0: /* bridge_gui.c */ truelight@0: void ShowBuildBridgeWindow(uint start, uint end, byte type); truelight@0: tron@1093: void ShowBuildIndustryWindow(void); truelight@4299: void ShowQueryString(StringID str, StringID caption, uint maxlen, uint maxwidth, WindowClass window_class, WindowNumber window_number, CharSetFilter afilter); truelight@4300: void ShowQuery(StringID caption, StringID message, void (*ok_cancel_callback)(bool ok_clicked), WindowClass window_class, WindowNumber window_number); tron@1093: void ShowMusicWindow(void); truelight@0: truelight@0: /* main_gui.c */ truelight@0: VARDEF byte _station_show_coverage; truelight@0: VARDEF PlaceProc *_place_proc; truelight@0: darkvater@1246: /* vehicle_gui.c */ darkvater@1246: void InitializeGUI(void); darkvater@1246: truelight@0: #endif /* GUI_H */