Skip to main content
dbDavideBoscolo
Braniac
March 14, 2022
Answered

CEP panel - title attribute line break

  • March 14, 2022
  • 2 replies
  • 504 views

Hi all,

I've noticed that the title attributes of my CEP panel sometimes aren't interpreted correctly. The problem is the line breaks. 
Nothing seems to fix this issues, that, as far as I know, only happens on Windows.

This is what it looks like when hovering over the L button (the same happens on the C E and V buttons):

 

And this is what it should always look like:

 

It's Javascript generated, and this is the code:

function titleAttributes(isWin){
  
  if (isWin){
    $("#div_copy").attr('title', 'Copy<br>+ Ctrl: duplicate<br>+ Alt: mirror');
    $("#div_ease").attr('title', 'Ease<br>+ Shift: in<br>+ Ctrl: mid<br>+ Alt: out<br>+ Shift + Ctrl: in and mid<br>+ Ctrl + Alt: mid and out');
    $("#div_value").attr('title', 'Value<br>+ Ctrl: value and spatial int.');
    $("#div_linearize").attr('title', 'Linearize<br>+ Shift: in<br>+ Ctrl: mid<br>+ Alt: out<br> + Shift + Ctrl: in and mid<br>+ Ctrl + Alt: mid and out');
  }else{
    $("#div_copy").attr('title', "Copy <br> + Opt: duplicate <br> + Command: mirror");
    $("#div_ease").attr('title', "Ease <br> + Shift: in <br> + Opt: mid <br> + Command: out <br> + Shift + Opt: in and mid <br> + Opt + Command: mid and out");
    $("#div_value").attr('title', "Value <br> + Command: value and spatial int.");
    $("#div_linearize").attr('title', "Linearize <br> + Shift: in <br> + Opt: mid <br> + Command: out <br> + Shift + Opt: in and mid <br> + Ctrl + Command: mid and out");
  }
  $("#div_ext").attr('title', 'Toggle between Libraries');
}


Any ideas?

This topic has been closed for replies.
Correct answer dbDavideBoscolo

It looks like using \n instead of <br> works fine.

2 replies

dbDavideBoscolo
dbDavideBoscoloAuthorCorrect answer
Braniac
March 15, 2022

It looks like using \n instead of <br> works fine.

Mylenium
Braniac
March 14, 2022

You can use double breaks. That's a common issue even in browsers...

 

Mylenium

dbDavideBoscolo
Braniac
March 15, 2022

Hi Mylenium,
do you mean by adding <br> twice? Because it doesn't seem to work.