File tree Expand file tree Collapse file tree
src/vs/editor/browser/viewParts/minimap Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -39,7 +39,8 @@ export class MinimapCharRenderer {
3939 ) : void {
4040 const charWidth = Constants . BASE_CHAR_WIDTH * this . scale ;
4141 const charHeight = Constants . BASE_CHAR_HEIGHT * this . scale ;
42- if ( dx + charWidth > target . width || dy + charHeight > target . height ) {
42+ const renderHeight = ( force1pxHeight ? 1 : charHeight ) ;
43+ if ( dx + charWidth > target . width || dy + renderHeight > target . height ) {
4344 console . warn ( 'bad render request outside image data' ) ;
4445 return ;
4546 }
@@ -61,7 +62,6 @@ export class MinimapCharRenderer {
6162 let sourceOffset = charIndex * charWidth * charHeight ;
6263
6364 let row = dy * destWidth + dx * Constants . RGBA_CHANNELS_CNT ;
64- const renderHeight = ( force1pxHeight ? 1 : charHeight ) ;
6565 for ( let y = 0 ; y < renderHeight ; y ++ ) {
6666 let column = row ;
6767 for ( let x = 0 ; x < charWidth ; x ++ ) {
You can’t perform that action at this time.
0 commit comments