class_docstr: A class for managing a circuit plot.
docstr: Create a list of all gates in the circuit plot.
docstr_tok: ["Create","a","list","of","all","gates","in","the","circuit","plot","."]
code: def _gates(self):
      """Create a list of all gates in the circuit plot."""
      gates = []
      if isinstance(self.circuit, Mul):
          for g in reversed(self.circuit.args):
              if isinstance(g, Gate):
                  gates.append(g)
      elif isinstance(self.circuit, Gate):
          gates.append(self.circuit)
      return gates
  
imports: from __future__ import annotations
  from sympy.core.mul import Mul
  from sympy.external import import_module
  from sympy.physics.quantum.gate import Gate, OneQubitGate, CGate, CGateS
label_desc: Use image node_id 7 for calling the CircuitPlot obj's underlying member method code with example usage: obj._gates() and returns: gates