Conversation
supportIf I embed a gist using the github gist embed code, the indentation is shown as expected. Using this plugin, it embeds gists lose their indentation. http://wordpress.org/extend/plugins/embed-github-gist/
Apologies – I can confirm this is a CSS rule causing this bug on my site. Will try to narrow it down and post a fix if anyone has the same issue maybe it will help. /withdrawn
It has something to do with pre { white-space: pre-wrap; } The problem is that if the gist loads with the css like above then it shows the indent and then you could change to… pre { white-space: nowrap; } …but if you have the nowrap before the gist loads you have the code not wrapping but no indention. I am not sure where the problem lies.
I’ve run into this same issue. I tried changing the CSS pre tag definition to no avail. Were you able to find the CSS issue?
I commented a few lines out of my theme’s stylesheet as follows: pre { padding: 10px; /*white-space: pre; white-space: pre-wrap; white-space: pre-line;*/ word-wrap: break-word; } Got one similar issue though – the line number margin varies in width according to the content of the code. Any ideas? See: http://bennuttall.com/comprehension-in-python/
I came across this today. I have not been able to test it yet. http://davidwalsh.name/tab-size
Apologies – I can confirm this is a CSS rule causing this bug on my site. Will try to narrow it down and post a fix if anyone has the same issue maybe it will help. /withdrawn
It has something to do with pre { white-space: pre-wrap; } The problem is that if the gist loads with the css like above then it shows the indent and then you could change to… pre { white-space: nowrap; } …but if you have the nowrap before the gist loads you have the code not wrapping but no indention. I am not sure where the problem lies.
I’ve run into this same issue. I tried changing the CSS pre tag definition to no avail. Were you able to find the CSS issue?
I commented a few lines out of my theme’s stylesheet as follows: pre { padding: 10px; /*white-space: pre; white-space: pre-wrap; white-space: pre-line;*/ word-wrap: break-word; } Got one similar issue though – the line number margin varies in width according to the content of the code. Any ideas? See: http://bennuttall.com/comprehension-in-python/
I came across this today. I have not been able to test it yet. http://davidwalsh.name/tab-size