Skip to content

Instantly share code, notes, and snippets.

View sourcerebels's full-sized avatar

Edu Rodríguez Castillo sourcerebels

View GitHub Profile
@sourcerebels
sourcerebels / 0_reuse_code.js
Created October 19, 2016 06:31
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
public static void setFirstLineBold(TextView tv) {
String txt = tv.getText().toString();
Spannable span = new SpannableString(txt);
int end = txt.indexOf('\n');
if (end == -1) {
end = txt.length();
}
span.setSpan(new StyleSpan(android.graphics.Typeface.BOLD), 0, end,