Advocates gather at a rally to support mandated increases in funding to pay those who work with people suffering from addiction and mental illness. (Josh Hicks/TWP)

Hundreds of advocates for mental-health and substance-abuse treatment rallied in Annapolis on Thursday for something Maryland Gov. Larry Hogan (R) is pushing to tame: automatic spending increases.

With the legislature nearing the halfway point of its 90-day session, activists gathered outside the State House to support legislation that would tie the state’s ­behavioral-health funding to the rate of inflation for medical costs.

Legislative analysts said the measure, sponsored by Sen. Guy J. Guzzone (D-Howard) and Del. Antonio L. Hayes (D-Baltimore), would require spending to be increased by nearly $17 million during the first year of implementation, with additional hikes during subsequent years.

Supporters said the legislation is needed to ensure the kind of fair, predictable rates that can help attract and retain qualified professionals to treat the addicted and mentally ill. They noted that the state has provided only six modest expansions of such funding in the past 20 years.

But controlling the state’s spending mandates has become a top priority for Hogan, who wants to avoid budget deficits that plagued his predecessor, Martin O’Malley (D), after the 2008 recession. Last month, Hogan proposed legislation that would pause some required spending increases during years when revenues are low, with exemptions for K-12 education, state pensions, reserve funds and debt payments.

Guzzone, speaking to the crowd less than an hour before a Senate Finance Committee hearing on his bill, encouraged lawmakers to embrace his proposed mandate, saying spending increases are needed to ensure quality services for a vulnerable population and should not be dependent on the whims of the governor or legislature in tough budget years.

“Sometimes that word in the budget world is a little scary for people,” he said of the term “mandate.” “I think what’s even scarier is that we don’t provide a consistent source of funding year after year. What happens is what has happened — a system that does not work for everyone.”

Hogan spokeswoman Shareese Deleaver-Churchill noted that the governor’s 2017 budget would increase spending on behavioral-health services by $3 million. “Putting aside the legislature’s apparent proclivity for more mandated spending at every opportunity, the governor does agree that taking care of Maryland’s most vulnerable citizens is a priority,” she said.

Thursday’s rally was organized by the Maryland Coalition of Families, a group that advocates for families with behavioral-health needs. The organization also supports legislation sponsored by Senate Majority Leader Catherine E. Pugh and Del. Samuel I. Rosenberg, both Baltimore Democrats, that would require the state to use existing funds to ensure around-the-clock availability of crisis walk-in services and mobile crisis teams.

Among the rally participants was Theresa Lord of Queen Anne’s County, who said her young daughter suffers from a “plethora” of mental-health problems that sometimes make her a threat to herself and others. Social workers known as “family navigators” were able to find resources to help.

“We were barely holding on as a family,” Lord said.

Lawmakers on Thursday also considered a bill that would allow doctors to prescribe lethal doses of medicine to dying patients who wish to end their lives and a measure to safeguard victims of lead-paint poisoning from financial exploitation.

Sen. Ronald N. Young (D-Frederick), sponsor of the right-to-die law that was heard in the Senate Judicial Proceedings Committee, said lawmakers should not stand in the way of eligible patients who want to end their suffering.

“It’s an individual decision,” he said. “I have people who say ‘I don’t like it,’ and my answer is: ‘Don’t do it.’ ”

The Catholic Church and advocates for the disabled have formed an alliance to fight Young’s bill, arguing that it could lead to abuse.

Advocates say the legislation has widespread public support, pointing to a recent Goucher College poll that found 60 percent of Maryland residents support allowing terminally ill adults to take their own lives. Thirty-five percent of respondents opposed the measure.

Sen. Robert A. Zirkin (D-Baltimore County), chairman of the Judicial Proceedings Committee and one of four undecided senators whose vote is needed to move the bill forward, said he is “very torn” about the proposal. He said he worries about patients ending their lives out of concern that they have become a burden to their families.

“It’s a very emotional issue,” he said. “I have personal stories from my own family on both sides, painful stories. . . . I genuinely don’t know.”

The lead-poisoning legislation, sponsored by House Speaker ­Michael E. Busch (D-Anne Arundel) and Senate President Thomas V. Mike Miller Jr. (D-Calvert), is designed to protect victims of lead-paint poisoning who receive legal settlements that often involve large payments spread out over decades.

A Washington Post investigation last year revealed that companies solicit individuals to sell their settlements for pennies on the dollar rather than waiting for the full payments. The settlements were usually highly favorable to the companies and often left unsophisticated or mentally disabled victims without the means to care for themselves. A separate review by Maryland Attorney General Brian E. Frosh (D) found similar results.

The legislation would require victims to receive independent advice on whether transferring their settlement payments is in their best interest and impose stricter standards of review for courts when they decide whether to approve or deny transfers. It would also allow the attorney general to regulate the companies involved in such transactions.

Rosenberg, a co-sponsor of the House bill, said the measure would “protect the interests of those who are being preyed upon.”

Also Thursday, Miller weighed in on Hogan’s backing of a bill to require live streaming and video archives of the legislature’s floor sessions. Miller said he would take the measure under consideration, but he added that the governor should avoid telling legislative leaders how to run their respective chambers.

“I’ll put the cameras in his office, and he can talk to the camera all day long,” the Senate president joked.