Linux: Debugger - Fixed line background color overlap with line selection rectangle
This commit is contained in:
parent
834773079c
commit
f9bb517b31
3 changed files with 7 additions and 6 deletions
|
@ -51,7 +51,7 @@ namespace Mesen.GUI.Debugger.Controls
|
|||
g.ScaleTransform(32, 32);
|
||||
g.DrawImageUnscaled(source, 0, 0);
|
||||
|
||||
g.ScaleTransform(1f/32, 1f/32);
|
||||
g.ResetTransform();
|
||||
Font font = new Font(BaseControl.MonospaceFontFamily, BaseControl.DefaultFontSize - 2, GraphicsUnit.Pixel);
|
||||
using(Brush bg = new SolidBrush(Color.FromArgb(150, Color.LightGray))) {
|
||||
for(int y = 0; y < 8; y++) {
|
||||
|
|
|
@ -837,7 +837,8 @@ namespace Mesen.GUI.Debugger
|
|||
|
||||
if(lineProperties.BgColor.HasValue) {
|
||||
using(Brush bgBrush = new SolidBrush(lineProperties.BgColor.Value)) {
|
||||
g.FillRectangle(bgBrush, marginLeft, positionY + 1, codeStringLength, lineHeight-1);
|
||||
int yOffset = Program.IsMono ? 2 : 1;
|
||||
g.FillRectangle(bgBrush, marginLeft, positionY + yOffset, codeStringLength, lineHeight-1);
|
||||
}
|
||||
}
|
||||
if(lineProperties.OutlineColor.HasValue) {
|
||||
|
@ -886,7 +887,7 @@ namespace Mesen.GUI.Debugger
|
|||
float textLength = g.MeasureString(text, this._noteFont, int.MaxValue, StringFormat.GenericTypographic).Width;
|
||||
g.DrawString(text, this._noteFont, fgBrush, (marginLeft + this.Width - textLength) / 2, positionY, StringFormat.GenericTypographic);
|
||||
g.DrawLine(Pens.Black, marginLeft, positionY+lineHeight-2, marginLeft+this.Width, positionY+lineHeight-2);
|
||||
g.TranslateTransform(-HorizontalScrollPosition * HorizontalScrollFactor, 0);
|
||||
g.ResetTransform();
|
||||
} else if(codeString.StartsWith("__") && codeString.EndsWith("__")) {
|
||||
//Draw block end
|
||||
g.TranslateTransform(HorizontalScrollPosition * HorizontalScrollFactor, 0);
|
||||
|
@ -894,7 +895,7 @@ namespace Mesen.GUI.Debugger
|
|||
float textLength = g.MeasureString(text, this._noteFont, int.MaxValue, StringFormat.GenericTypographic).Width;
|
||||
g.DrawString(text, this._noteFont, fgBrush, (marginLeft + this.Width - textLength) / 2, positionY + 4, StringFormat.GenericTypographic);
|
||||
g.DrawLine(Pens.Black, marginLeft, positionY+2, marginLeft+this.Width, positionY+2);
|
||||
g.TranslateTransform(-HorizontalScrollPosition * HorizontalScrollFactor, 0);
|
||||
g.ResetTransform();
|
||||
} else {
|
||||
//Draw line content
|
||||
g.DrawString(codeString, this.Font, fgBrush, marginLeft, positionY, StringFormat.GenericTypographic);
|
||||
|
@ -1060,7 +1061,7 @@ namespace Mesen.GUI.Debugger
|
|||
currentLine++;
|
||||
}
|
||||
|
||||
pe.Graphics.TranslateTransform(HorizontalScrollPosition * HorizontalScrollFactor, 0);
|
||||
pe.Graphics.ResetTransform();
|
||||
|
||||
if(this.ShowLineNumbers) {
|
||||
using(Brush brush = new SolidBrush(Color.FromArgb(235, 235, 235))) {
|
||||
|
|
|
@ -78,7 +78,7 @@ namespace Mesen.GUI.Debugger
|
|||
g.DrawImageUnscaled(source, -8, 4);
|
||||
|
||||
if(this.ShowColorIndexes) {
|
||||
g.ScaleTransform(1f/42, 1f/42);
|
||||
g.ResetTransform();
|
||||
using(Brush bg = new SolidBrush(Color.FromArgb(150, Color.LightGray))) {
|
||||
for(int y = 0; y < 8; y++) {
|
||||
for(int x = 0; x < 8; x++) {
|
||||
|
|
Loading…
Add table
Reference in a new issue