Do commutative Banach algebras with totally disconnected spectrum have linearly dense idempotents? Suppose that $A$ is a unital commutative Banach algebra. It is a nice application of the Shilov idempotent theorem that if the spectrum of $A$ is totally disconnected, then $A$ is regular.

Can we show that idempotents in $A$ are linearly dense if the spectum of $A$ is totally disconnected? 

I think it must be known. This is really asking for the converse to this fact.
 A: A totally disconnected spectrum doesn't imply a dense span of the idempotents.
Let's look first at the silly example $A_0 = \mathbb{C}^2$, endowed with the norm $\lVert (x,y)\rVert_{A_0} = \lvert x\rvert + \lvert y\rvert$ and the multiplication $(u,v)\cdot (x,y) = (ux, uy + vx)$, so $A_0 \cong \mathbb{C}[X]/(X^2)$, endowed with the $\ell^1$-norm. One verifies that this is a unital commutative Banach algebra, and its only idempotent elements are $e_0 = (1,0)$ and $0$, so the linear span of the idempotents is not dense. The spectrum of $A_0$ is a singleton (the only unital algebra homomorphism to $\mathbb{C}$ is the first coordinate projection), so it's totally disconnected (and connected).
We use that to construct a less silly example, in which the spectrum is totally disconnected and not connected. Let $A_1$ be a unital commutative Banach algebra with (nonempty) totally disconnected spectrum, for example $A_1 = C(K,\mathbb{C})$, where $K$ is the Cantor set ($A_0$ would also work). Let $A = A_0 \times A_1$, with componentwise multiplication, and endow it with the norm $\lVert (x,y)\rVert_A = \max \{ \lVert x\rVert_{A_0}, \lVert y\rVert_{A_1}\}$. That makes $A$ a unital commutative Banach algebra, and the idempotents in $A$ are the pairs $(x,y)$ where $x$ is an idempotent in $A_0$ and $y$ an idempotent in $A_1$. So the span of idempotents is not dense, $((0,1),0)$ does not belong to the closure of that span. Since $A_0 \times \{0\}$ and $\{0\} \times A_1$ are ideals in $A$, it follows that every unital homomorphism $A\to \mathbb{C}$ is either $\psi_0 \colon ((u,v),w) \mapsto u$ or $(x,y) \mapsto \lambda(y)$ with $\lambda \in \Delta(A_1)$. Thus $\Delta(A) \cong \Delta(A_1) \cup \{\psi_0\}$, where $\psi_0$ is an isolated point, so totally disconnected.
It would be interesting to investigate whether the presence of nilpotent elements is the only thing that can make the span of idempotents non-dense if the spectrum is totally disconnected.
