MathView icon indicating copy to clipboard operation
MathView copied to clipboard

Text alignment left

Open mikelantzelo opened this issue 6 years ago • 4 comments

Text alignment left is not working with either with xml or java set. Can you help me?

mikelantzelo avatar Mar 01 '18 12:03 mikelantzelo

@mikelantzelo Can you please share the code snippet and also the relevant screenshot.

Nishant-Pathak avatar Mar 01 '18 14:03 Nishant-Pathak

@Nullable @Override public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { View view = inflater.inflate(R.layout.dialog_show_answer, container, false); context = getActivity(); getDialog().setTitle(R.string.apantisi); MathView mathView = view.findViewById(R.id.html_text); Button button = view.findViewById(R.id.button_apantisi_ok); mathView.setTextAlignment(View.TEXT_ALIGNMENT_TEXT_START); mathView.setText(answer); button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { getDialog().dismiss(); } });

    return view;
}

screenshot_1519920211

mikelantzelo avatar Mar 01 '18 16:03 mikelantzelo

Thanks @mikelantzelo to raise this concern. Do you mind having a look to MathView.java class and figure out the fix. I will be happy to see pull request for this.

Nishant-Pathak avatar Mar 03 '18 08:03 Nishant-Pathak

Hello! I think it may related to the MathJax which display everything in center by default. (I'm not familiar with it so i am just gussing) and maybe you can check here: https://stackoverflow.com/questions/11296415/how-to-left-align-mathjax-elements

Steve-Mr avatar Apr 20 '19 17:04 Steve-Mr