What is the proper way to separate programs?

Say one has reached a point of having to program a way to switch programs.

Right now I’m thinking it might be ideal to separate “drawing entities” into groups of programs and perhaps other data.

For instance, a “font entity” or a “static mesh entity”. Each might have its own GLSL program but also other data such as its own lighting etc.

Do you know of a better way?

That’s the preferred way to do it: use a variety of simple separate shader programs to render different types of things rather than one giant complex shader program that renders everything.