Coming to terms with imminent death is not an easy subject for a film, but Cesc Gay treats it with commendable delicacy, a welcome absence of sentimentality, and not a little humor, in “Truman.” The title character is not the dying man, Julian (Ricardo Darin), an Argentinean actor long resident in Madrid, but his pet, an aged bulldog for which he’s trying to find a new home before his demise. Psychologists might consider his inordinate concern for Truman a sort of displacement of the emotions he should be feeling about himself, or about the people around him, including his sister Paula (Dolores Fonzi), though one needn’t understand it in precisely those terms.

Paula is understandably distressed over Julian’s decision to forgo further treatment for his advanced lung cancer, which we learn he’s been battling for a year. Apparently it is she who has persuaded her brother’s best friend Tomas (Javier Camara), a teacher who’s lived in Canada for many years with a growing family, to make a sudden trip to Spain to visit with Javier for a few days. The hope is that Tomas will be able to convince his friend to rethink that choice.

It quickly becomes clear that if such was the intention, it appears to be a non-starter. One of the first sequences in the episodic script Gay has confected with Tomas Aragay is a visit in which Tomas accompanies Javier to his doctor (Pedro Casablanc), who is ready to prescribe a further sequence of treatments which Javier determinedly rejects on the quite reasonable basis that they would, at best, extend his life for a minimal length of time. Tomas’ failure will disappoint Paula, but it will not stop the two of them from renewing their acquaintance in a fashion that will be revealed only toward the picture’s close, in a twist that isn’t terribly surprising though—given Tomas’ situation back in Canada—it might be a mite unsettling.

On the way to that revelation, Javier and Tomas will share a variety of other episodes. Some are quite emotional, like a spur-of-the-moment visit to Javier’s son Nico (Oriol Pla) in Amsterdam, where he’s a university student—a visit that shortly takes on an added dimension when they encounter Javier’s ex-wife Gloria (Elvira Minguez), who has also been in touch with Nico. Others are only marginally less so, such as accidental meetings with Javier’s fellow actors—a couple which Javier confronts when they pretend not to see him, and Luis (Eduard Fernandez), who greets him sympathetically despite the fact that Javier had undercut his marriage by sleeping with his wife—or a dressing-room confrontation with the aged producer (Jose Luis Gomez) of the play in which Javier is currently appearing, who obliquely, almost apologetically, fires him, having just learned of his condition.

Other incidents are less wrenching. When Tomas visits Truman’s vet (Alex Brendemuhl) with Javier, for example, the conversation turns to how an animal might react to the death of its owner, and the poor fellow seems flummoxed by the query. A sequence in which the men visit a funeral director (Javier Gutierrez) is even more comic, though in a rather dark way. Then there are the interviews Javier conducts with the dog’s potential new owners—a lesbian couple in the first instance, a divorced woman in the second. Javier’s ultimate decision in that matter is not entirely unpredictable, but it forms a nice coda to the film. And interspersed among the various episodes are walks about the city by the two men, during which they engage in sometimes humorous, sometimes serious recollections about their past history and sometimes rueful, sometimes jovial observations on their present circumstances.

The screenplay of “Truman” provides a fine foundation for a touching, insightful film, but it requires two engaging actors to realize its potential, and Darin and Camara certainly fill the bill. Javier is the showier role, but Darin approaches it with sensitivity rather than excess, underplaying more often than not. Camara is even more reserved, so that on the rare occasions when he gives his passions free rein, the impact is all the greater. The supporting cast is uniformly fine, with Fonzi standing out as a woman of conflicting emotions and Pla as a young man of hidden ones. The technical side of the picture is excellent, with cinematographer Andreu Rebes’ subdued use of the Madrid and Amsterdam locations (as well as the snowy Canadian ones of the early scenes) endowing an appropriately autumnal feel, abetted by Pablo Barbieri’s unfussy, leisurely editing.

Medieval theologians made texts called “de arte moriendi”—literally on the art of dying, or how to die well—a popular genre. “Truman” might not offer the kind of answer they aimed for, but it is an artful portrayal of how one man tries to prepare for the inevitable—with a little help from his friends, including a dog that’s also on its last legs.