Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

All my text is black #60298

Closed
stephen-oh opened this issue Oct 9, 2018 · 46 comments
Closed

All my text is black #60298

stephen-oh opened this issue Oct 9, 2018 · 46 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority themes Color theme issues verified Verification succeeded
Milestone

Comments

@stephen-oh
Copy link

Issue Type: Bug

After the update my text is now all black apart from on the files im editing. I have changed theme and its the same in most dark themes

VS Code version: Code 1.28.0 (431ef9d, 2018-10-05T14:58:53.203Z)
OS version: Windows_NT x64 10.0.17134

System Info
Item Value
CPUs Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz (8 x 2112)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
Memory (System) 15.88GB (5.45GB free)
Process Argv
Screen Reader no
VM 0%
Extensions: none
@vscodebot vscodebot bot added the new release label Oct 9, 2018
@stephen-oh
Copy link
Author

Fixed with a restart

@stephen-oh stephen-oh reopened this Oct 10, 2018
@stephen-oh
Copy link
Author

image

@stephen-oh
Copy link
Author

Restarting no longer fixing the issue. No extensions installed, settings are seldom changed except for theme. All dark themes have this issue

@egamma
Copy link
Member

egamma commented Oct 10, 2018

Can you reproduce this using the Dark+ theme?

What theme are you currently using?

@egamma egamma added the info-needed Issue requires more information from poster label Oct 10, 2018
@stephen-oh
Copy link
Author

I'm using the Monokai theme, the issue appears with the Dark+ theme also

@stephen-oh
Copy link
Author

image

@egamma egamma removed the info-needed Issue requires more information from poster label Oct 10, 2018
@isidorn
Copy link
Contributor

isidorn commented Oct 10, 2018

Can you reproduce with vscode insiders? https://code.visualstudio.com/insiders/
What if you open some other viewlet like search, do you also see it there?
Are you sure you do not have some user / workspace settings which change the color of the tree foreground?

@isidorn isidorn added the info-needed Issue requires more information from poster label Oct 10, 2018
@stephen-oh
Copy link
Author

Just installed insiders and get the same issue
image

Here's the search
image

No config settings - this is VS Code
image

@isidorn
Copy link
Contributor

isidorn commented Oct 10, 2018

Looks like electron fyi @bpasero
How about with electron 3.0?
Windows: Download

@bpasero
Copy link
Member

bpasero commented Oct 10, 2018

We are building exploration builds that use a much newer version of Electron (our UI framework). I wonder if this issue reproduces with one of these builds, could you try? Download:

@stephen-oh
Copy link
Author

image
Same again

@isidorn
Copy link
Contributor

isidorn commented Oct 10, 2018

@Patches- and opening chrome just a random website everything is rendered correctly?

@stephen-oh
Copy link
Author

image

@stephen-oh
Copy link
Author

Sometimes when I open VSC it will have the white text as expected for a split second then it changes to black

@bpasero
Copy link
Member

bpasero commented Oct 10, 2018

@Patches- does it reproduce if you run code --disable-gpu?

@stephen-oh
Copy link
Author

@bpasero Running that fixes the issue

@bpasero bpasero added upstream Issue identified as 'upstream' component related (exists outside of VS Code) electron Issues and items related to Electron gpu Issues concerning GPU related items labels Oct 10, 2018
@bpasero bpasero assigned bpasero and unassigned isidorn Oct 10, 2018
@bpasero bpasero removed the info-needed Issue requires more information from poster label Oct 10, 2018
@fbalhawan
Copy link

I'm still facing the issue here even with running code --disable-gpu

@fbalhawan
Copy link

@bpasero Thanks for following up. I have went with a better temporary solution. I added
.vs-dark{color:#cccccc}
in workbench.main.css under %localappdata%\Programs\Microsoft VS Code\resources\app\out\vs\workbench

@BartInTheField
Copy link

@fbalhawan That temporary solution worked for me as well

@bpasero
Copy link
Member

bpasero commented Oct 12, 2018

More people seem to hit this, I wonder if this is due to the Windows October update. Do people have this installed?

Adding another brain (@aeschli) to this to put in ideas.

@bpasero
Copy link
Member

bpasero commented Oct 12, 2018

@fbalhawan @BartInTheField trying to understand if this is a regression from our 1.28 update, does it reproduce with the 1.27 build? Download

@BartInTheField
Copy link

@bpasero My text was fine in the 1.27 build

@aeschli
Copy link
Contributor

aeschli commented Oct 12, 2018

I suspect there's a syntax error in the dynamic css that we generate.
@BartInTheField @fbalhawan When you have the dev tools open, can you paste the following into the console and press enter.

  el = document.createElement('textarea');
  el.value = document.getElementsByClassName('contributedColorTheme')[0].textContent;
  document.body.appendChild(el);
  el.select();
  document.execCommand('copy');
  document.body.removeChild(el);

This will copy our dynamic css to the clipboard. You can then paste what yoy get into the issue here or a gist

image

Here's what I get: https://gist.github.com/aeschli/ee9fdbdb3a87c8ac1d4540aa91999bfe

@fbalhawan
Copy link

@bpasero as @BartInTheField said, it also worked for me when i tried the version 1.27
@aeschli Here's the CSS copied to my clipboard when executing your script: https://gist.github.com/fbalhawan/4c8b94344d38de2372334af1ae01a96c

I have tried to do a comparison with a merging tool, but it wasn't that helpful for me

@bpasero bpasero added this to the October 2018 milestone Oct 13, 2018
@bpasero
Copy link
Member

bpasero commented Oct 13, 2018

@aeschli thank you, I think we are on the right path

Looks like this CSS rule is causing issues:

.monaco-workbench > .part.editor > .content .editor-group-container.empty .editor-group-letterpress {
    background-image: url('c:/Users/Fouad's HP/AppData/Local/Programs/Microsoft VS Code/resources/app/resources/letterpress-dark.svg')
}

@fbalhawan is your user name Fouad's HP?

@BartInTheField what about your user name?

I do not understand how this could have worked in 1.27. @fbalhawan can you do the same with 1.27 and paste the CSS value here?

@bpasero bpasero added bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority labels Oct 13, 2018
@fbalhawan
Copy link

@bpasero lol! yup, that's my PC's username.
for 1.27, here's the CSS value: https://gist.github.com/fbalhawan/7cd468150988fa0c4f4fc28795b6b46b

I'm in a bit of a hurry and haven't read it, but it might be that the css element changing the color value of the menu text is written before the syntax error shown in version 1.27

@bpasero
Copy link
Member

bpasero commented Oct 13, 2018

@fbalhawan thanks, the issue exists in that version too but it is possible that we changed some order so that the impact is less noticeable.

Meanwhile I am able to reproduce this by simply having a single quote in the folder from where I launch VSCode. It looks like this change fixes it:

collector.addRule(`
	.monaco-workbench > .part.editor > .content .editor-group-container.empty .editor-group-letterpress {
		background-image: url('${CSS.escape(join(environment.appRoot, letterpress).replace(/#/g, '%23'))}')
	}
`);

@aeschli I am not 100% sure this is the right solution though, maybe you could confirm. When I do a search for : url( in *.ts I see many more places where we construct a URL based on some path and I do not see the usage of CSS.escape() in any of them.

@bpasero bpasero added themes Color theme issues candidate Issue identified as probable candidate for fixing in the next release labels Oct 13, 2018
@aeschli
Copy link
Contributor

aeschli commented Oct 14, 2018

@bpasero The sugget to turn the path in a URI and use toString
background-image: url('${Uri.file(join(environment.appRoot, letterpress)).toString()}')
I looked at other places where we emit css uris and I saw only URIs there.

@bpasero bpasero removed the info-needed Issue requires more information from poster label Oct 15, 2018
@bpasero bpasero closed this as completed Oct 15, 2018
bpasero added a commit that referenced this issue Oct 15, 2018
@BartInTheField
Copy link

Yes my username is 'Bartin'tVeld' so that seems to be the issue

@stephen-oh
Copy link
Author

Ah yes that'll be my issue also then "C:\Users\Stephen O'Hara"

@bpasero bpasero removed candidate Issue identified as probable candidate for fixing in the next release labels Oct 15, 2018
@RMacfarlane RMacfarlane added the verified Verification succeeded label Oct 31, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 29, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority themes Color theme issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

8 participants