Scotland has revised guidance for sex and relationship education to include more on gay relationships – but faith schools will still be allowed to set their own lessons instead.

The new framework, which was published this week, updates regulations that are 14 years out of date, to take account of changes including civil partnerships and same-sex marriage.

Homophobic and transphobic bullying are also to be emphasised, while it also warns of the dangers of ‘sexting’ and the internet.

However, campaigners have criticized concessions which allow parents to withdraw children from Relationships, Sexual Health and Parenthood (RSHP) lessons, permit faith schools to provide alternative teachings within their “ethos”, and allow individuals teachers to opt out.

The Humanist Society of Scotland lambasted the government’s decision to maintain a faith school “veto” over some aspects of sex and relationship education.

A statement said: “HSS are deeply disappointed that faith schools, which account for more than 1-in-5 school placements in Scotland, would retain an effective veto and a curriculum dictated by the Roman Catholic Bishops’ Conference.

“HSS is also very disappointed that if a teacher objects to aspects of RSHP education then they have the option to withdraw. Teaching is about equipping children for the world as it is, not as a teacher may want it to be.

“By withdrawing from this important part of their education, a teacher is failing in their duty.”

HSS Policy officer Gary McLelland said: “It’s fantastic to see the Government acknowledge the high levels of homophobic, biphobic and transphobic bullying taking place in Scottish schools, and to issue clear guidance for dealing with this.

“It is deeply disappointing that such guidance will be effectively optional for faith schools, in which over 20% of young Scots are educated.

“At HSS we believe that ALL young people deserve access to high quality RSHP education, regardless of whether they happen to attend a faith school or not.”