FSO.Client.UI.Panels.UIPropertyLog.RenderEvents C# (CSharp) Method

RenderEvents() public method

public RenderEvents ( ) : void
return void
        public void RenderEvents()
        {
            StringBuilder txt = new StringBuilder();
            bool first = true;
            foreach (var evt in History)
            {
                if (!first) txt.Append("\r\n");
                first = false;
                txt.Append(RenderEvent(evt));
            }

            bool scroll = ChatHistoryText.VerticalScrollMax == ChatHistoryText.VerticalScrollPosition;
            ChatHistoryText.CurrentText = txt.ToString();
            ChatHistoryText.ComputeDrawingCommands();
            if (scroll)
            {
                ChatHistoryText.VerticalScrollPosition = ChatHistoryText.VerticalScrollMax;
            }
            else
            {
                ChatHistoryText.VerticalScrollPosition = ChatHistoryText.VerticalScrollPosition;
            }
        }