Hi, 
I am sorry that Origin ini can only support two %d in legend text. I have submitted a tracker #12269 and we will fix it 
Before we get it fixed, you can use following labtalk script to update the legend
layer -c;
string str;
str$="";
loop (ii, 1, count)  {str$=str$+"\l($(ii)) %%($(ii), @WS)_%%($(ii), @LS)%(crlf)";};
legend.text$=str$;