public static bool AddButton(string text, float x = 20, float width = 180) { var result = GUI.Button(new Rect(x, RCM.Y, width, 20), text); RCM.IncreaseY(); return(result); }
public static float AddSlider(ref float updateValue, float minValue, float maxValue, string text, float x = 160, float width = 210, float height = 30) { AddLabel(text, 20, 150); RCM.IncreaseY(-30); updateValue = GUI.HorizontalSlider(new Rect(x, RCM.Y + 3f, width, height), updateValue, minValue, maxValue); RCM.IncreaseY(); return(updateValue); }
private void LoadFrame() { if (_cRcm != null) { _cRcm.Dispose(); } _cRcm = new RCM(this.Handle); _cRcm.LeftFrameGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_FrameLeft; _cRcm.RightFrameGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_FrameRight; _cRcm.CaptionBarGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_FrameTop; _cRcm.BottomFrameGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_FrameBottom; _cRcm.CloseButtonGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_closebutton; _cRcm.MaximizeButtonGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_maxbutton; _cRcm.RestoreButtonGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_restorebutton; _cRcm.MinimizeButtonGraphic = Personal_Wave_Recorder.Properties.Resources.vienna_minbutton; }
public static void AddLabel(string text, float x = 20, float width = 150) { GUI.Label(new Rect(x, RCM.Y, width, 20), text, RCM.labelStyle); RCM.IncreaseY(); }
public static bool AddCheckBox(ref bool updateValue, string label) { updateValue = GUI.Toggle(new Rect(20, RCM.Y, RCM.MenuRect.width - 50, 30), updateValue, label); RCM.IncreaseY(); return(updateValue); }