  This paper is the first paper of three papers in a series, which intend to
provide a systematic treatment for the space-filling curves of self-similar
sets.
  In the present paper, we introduce a notion of \emph{linear graph-directed
IFS} (linear GIFS in short). We show that to construct a space-filling curve of
a self-similar set, it is amount to explore its linear GIFS structures. Some
other notions, such as chain condition, path-on-lattice IFS, and visualizations
of space-filling curves are also concerned.
  In sequential papers \cite{Dai15} and \cite{RZ14}, we obtain a universal
algorithm to construct space-filling curves of self-similar sets of finite
type, that is, as soon as the IFS is given, the computer will do everything
automatically.
  Our study extends almost all the known results on space-filling curves.
