Hmmm...
I tried your project on my old ZTE Blade that's running CyanogenMod Gingerbread 2.3 and it worked as expected.
I then added an asterix between the two bold spans of text and again it worked as expected, each bold span of text raising the correct ClickableSpan Click event (see attached demobold_labelextras_blade.png).
Note that the text is correctly aligned as 'right to left' text.
Next i tried your project on my Galaxy Tab2 running Jelly Bean 4.1.1, the text is aligned as 'left to right' text and no clicks are detected (see attached demobold_labelextras_tab2.png).
Appending the character
A to the string caused the bold spans to be clickable but they were still displayed as 'left to right' text.
Appending a space (instead of an A) to the string caused the bold spans to be not clickable.
I then tried surrounding your text in an HTML SPAN element:
s="<span>کارگه <b>سلام</b> * <b>خوبی</b> چه خبر </span>"&CRLF
The bold spans were no longer clickable.
Using an HTML P element was the same - the bold spans were not clickable.
I tried adding a new method to the Html object:
/**
* Returns displayable styled text from the provided HTML string specifying the character encoding of the string.
*/
public static CharSequence FromHtml3(String HtmlString, String Encoding) throws UnsupportedEncodingException {
return android.text.Html.fromHtml(new String(HtmlString.getBytes(), Encoding));
}
And updating the b4a code to use this new method:
Dim s As String
s="کارگه <b>سلام</b> * <b>خوبی</b> چه خبر "&CRLF
' s="Aکارگه <b>سلام</b> * <b>خوبی</b> چه خبر "&CRLF
Dim HtmlString As String=s
SpannableStringBuilder1.Initialize(Html1.FromHtml3(HtmlString, "UTF-8"))
This made no difference, the results were exactly as before.
Finally i tried appending the character A to the string and then removing it from the SpannableStringBuilder:
s="Aکارگه <b>سلام</b> * <b>خوبی</b> چه خبر "&CRLF
Dim HtmlString As String=s
SpannableStringBuilder1.Initialize(Html1.FromHtml(HtmlString))
SpannableStringBuilder1.Delete(0, 1)
The A is removed but now the bold spans are no longer clickable.
So the problem is likely to be device specific and (more accurately) android version specific i think.
It works perfectly on Gingerbread 2.3, the text is displayed as right to left text and the bold spans are clickable.
On Jelly Bean the only way that i could make the bold spans clickable was to display a single english character (A) with the foreign text.
I'm not sure what to suggest next

.
Martin.