Minted snippet with single quotesUsing minted with mixed Python code and outputHow to let minted highlight a...

Writing rule stating superpower from different root cause is bad writing

Arthur Somervell: 1000 Exercises - Meaning of this notation

Can I make popcorn with any corn?

Watching something be written to a file live with tail

Test whether all array elements are factors of a number

Why doesn't Newton's third law mean a person bounces back to where they started when they hit the ground?

Why does Kotter return in Welcome Back Kotter?

Why doesn't H₄O²⁺ exist?

What do the dots in this tr command do: tr .............A-Z A-ZA-Z <<< "JVPQBOV" (with 13 dots)

Why do falling prices hurt debtors?

How does one intimidate enemies without having the capacity for violence?

Minkowski space

can i play a electric guitar through a bass amp?

Risk of getting Chronic Wasting Disease (CWD) in the United States?

To string or not to string

Why "Having chlorophyll without photosynthesis is actually very dangerous" and "like living with a bomb"?

tikz: show 0 at the axis origin

Fencing style for blades that can attack from a distance

LaTeX closing $ signs makes cursor jump

Are the number of citations and number of published articles the most important criteria for a tenure promotion?

Prove that NP is closed under karp reduction?

Why can't I see bouncing of a switch on an oscilloscope?

Can a Warlock become Neutral Good?

Mage Armor with Defense fighting style (for Adventurers League bladeslinger)



Minted snippet with single quotes


Using minted with mixed Python code and outputHow to let minted highlight a whole file from diskUse of \minted@pygmentize doesn't match its definitionAdding additional blank lines in MintedMinted working from terminal but not TexpadMinted+Inconsolata: Straight QuotesReference Code snippet in latex using mintedtcolorbox minted library with python3 non-determinismSyntax highlighting in minted - how does it work?Display character % with mintedminted environment with prefix













1















I want to create a Python's code snippet which includes single quotes using minted package. I've put it altogether like this:



begin{minted}[
autogobble,
frame=lines,
framesep=4mm,
fontfamily=fdm,
fontsize=footnotesize,
python3=true,
style=vs]{python}
>>> D.mro()
[<class '__main__.D'>, <class '__main__.B'>, <class '__main__.C'>,
<class '__main__.A'>, <class 'object'>]
end{minted}


But the output does look a bit odd:



Minted handling single quotes



However changing single quotes to double quotes does not seem to work either. Does anyone know how to fix such behaviour? Thanks










share|improve this question









New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





















  • Using listings doesn't lead to this issue so I think this is a bug of Pygments.

    – JouleV
    11 hours ago











  • You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

    – marthin23
    11 hours ago











  • Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

    – TeXnician
    11 hours ago








  • 1





    Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

    – TeXnician
    11 hours ago
















1















I want to create a Python's code snippet which includes single quotes using minted package. I've put it altogether like this:



begin{minted}[
autogobble,
frame=lines,
framesep=4mm,
fontfamily=fdm,
fontsize=footnotesize,
python3=true,
style=vs]{python}
>>> D.mro()
[<class '__main__.D'>, <class '__main__.B'>, <class '__main__.C'>,
<class '__main__.A'>, <class 'object'>]
end{minted}


But the output does look a bit odd:



Minted handling single quotes



However changing single quotes to double quotes does not seem to work either. Does anyone know how to fix such behaviour? Thanks










share|improve this question









New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





















  • Using listings doesn't lead to this issue so I think this is a bug of Pygments.

    – JouleV
    11 hours ago











  • You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

    – marthin23
    11 hours ago











  • Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

    – TeXnician
    11 hours ago








  • 1





    Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

    – TeXnician
    11 hours ago














1












1








1








I want to create a Python's code snippet which includes single quotes using minted package. I've put it altogether like this:



begin{minted}[
autogobble,
frame=lines,
framesep=4mm,
fontfamily=fdm,
fontsize=footnotesize,
python3=true,
style=vs]{python}
>>> D.mro()
[<class '__main__.D'>, <class '__main__.B'>, <class '__main__.C'>,
<class '__main__.A'>, <class 'object'>]
end{minted}


But the output does look a bit odd:



Minted handling single quotes



However changing single quotes to double quotes does not seem to work either. Does anyone know how to fix such behaviour? Thanks










share|improve this question









New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












I want to create a Python's code snippet which includes single quotes using minted package. I've put it altogether like this:



begin{minted}[
autogobble,
frame=lines,
framesep=4mm,
fontfamily=fdm,
fontsize=footnotesize,
python3=true,
style=vs]{python}
>>> D.mro()
[<class '__main__.D'>, <class '__main__.B'>, <class '__main__.C'>,
<class '__main__.A'>, <class 'object'>]
end{minted}


But the output does look a bit odd:



Minted handling single quotes



However changing single quotes to double quotes does not seem to work either. Does anyone know how to fix such behaviour? Thanks







minted python






share|improve this question









New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited 11 hours ago







marthin23













New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 11 hours ago









marthin23marthin23

183




183




New contributor




marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






marthin23 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.













  • Using listings doesn't lead to this issue so I think this is a bug of Pygments.

    – JouleV
    11 hours ago











  • You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

    – marthin23
    11 hours ago











  • Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

    – TeXnician
    11 hours ago








  • 1





    Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

    – TeXnician
    11 hours ago



















  • Using listings doesn't lead to this issue so I think this is a bug of Pygments.

    – JouleV
    11 hours ago











  • You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

    – marthin23
    11 hours ago











  • Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

    – TeXnician
    11 hours ago








  • 1





    Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

    – TeXnician
    11 hours ago

















Using listings doesn't lead to this issue so I think this is a bug of Pygments.

– JouleV
11 hours ago





Using listings doesn't lead to this issue so I think this is a bug of Pygments.

– JouleV
11 hours ago













You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

– marthin23
11 hours ago





You're right, since the snippet represents the console output after the python's code execution, one workaround might be changing the language from python to bash.

– marthin23
11 hours ago













Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

– TeXnician
11 hours ago







Have a look at tex.stackexchange.com/questions/36889/… (in short: test the pycon lexer).

– TeXnician
11 hours ago






1




1





Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

– TeXnician
11 hours ago





Just a warning: The pycon lexer does output different classifications so your chosen vs style will not work (in case you wonder why everything is black) ;)

– TeXnician
11 hours ago










0






active

oldest

votes












Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "85"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});






marthin23 is a new contributor. Be nice, and check out our Code of Conduct.










draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483516%2fminted-snippet-with-single-quotes%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes








marthin23 is a new contributor. Be nice, and check out our Code of Conduct.










draft saved

draft discarded


















marthin23 is a new contributor. Be nice, and check out our Code of Conduct.













marthin23 is a new contributor. Be nice, and check out our Code of Conduct.












marthin23 is a new contributor. Be nice, and check out our Code of Conduct.
















Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483516%2fminted-snippet-with-single-quotes%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Paper upload error, “Upload failed: The top margin is 0.715 in on page 3, which is below the required...

Emraan Hashmi Filmografia | Linki zewnętrzne | Menu nawigacyjneGulshan GroverGulshan...

How can I write this formula?newline and italics added with leqWhy does widehat behave differently if I...