I've been experimenting on applying a gradient in the stroke of a live text object, while having the fill empty. I was able to achieve this by adding different effects such as Offset path and Outline stroke, the problem is, that sometimes it works, and sometime it doesn't.
I'm attaching a few screenshots on how I achieved it in the object I was able to, when I tried to replicate it by following the exact same steps and keeping the exact same stack order on the appearance palette, I was successful some of the times, I even tried copying the appearance by dragging the little black dot on the layers palette and the result was different.
Can anyone shed some light on the definitive rules about how this effects work? Right now it's very confusing.
As you can see, by default, the text is black. In the appearance palette it has no stroke and fill. However, if you double click the "Characters" entry, then it will reveal that the individual characters do have a black fill, but as a "Type" object it does not. It's because the text is live.
Normally you cannot apply a gradient to the stroke of a live text, but you can fake it as pictured. Click the "Add New Fill" button (or select it from the palette's menu). You will apply the gradient to this fill. Then add another fill and color it white. This second fill should be on top of the first (gradient) one. Now apply an Offset Path effect, and drag it inside the white fill entry. Now click on the Offset Path entry and adjust it to a negative value. This will in effect create the illusion as if the inner (white) fill is being reduced, thus revealing the gradient fill below it.
Now you can drag this text onto the Graphic Styles palette to create a new style, and use it to apply it to a new text with a single click.
I know about the extra fill and offset to fake a stroke, unfortunately I can't use it this time, because I need the type to be truly with no filling, so I can see whatever it's behind.
As mentioned, I was able to to it, but it only works some of the times, some others just doesn't. I experimented with both the offset path effect and the outline stroke effect, it really has me perplexed.
I have the file that has the gradient on the stroke with no fill, it's a CS5 file, let me know if you'd like to take a look at it.