6

From my thesis:

In this method, the get_config_value function is used that is defined within the PyWPS API.

How should I format the "get_config_value" variable?

It should be formatted differently than the rest of the text, but I don't know what the conventions are. Using italic or bold fonts doesn't look right to me.

Nat
  • 6,227
  • 3
  • 23
  • 45
Jan Pisl
  • 267
  • 1
  • 8
  • Do you mean that get_config_value is that variable? – Massimo Ortolano Jan 13 '18 at 14:15
  • yes. i should have used another sentence as an example. here it is not a variable as such, but a name of a function. still, i feel it should be formatted differently then the rest of the text. – Jan Pisl Jan 13 '18 at 14:18

1 Answers1

11

It is common to typeset code with a monospaced font (a font whose characters have all the same width), like get_config_value.

If you're using LaTeX to write your thesis, you can use the command \texttt for inline code. For clarity and flexibility, it's probably better to define a new command, e.g. \newcommand{\code}[1]{\texttt{#1}}. You can use the listings package for longer pieces of code.

For other typesetting systems or word processors, check their manual.

Massimo Ortolano
  • 55,428
  • 19
  • 166
  • 207