Buggy code:
public class StopwatchFragment extends Fragment implements SensorEventListener , View . OnClickListener { private Sensor mSensor ; private SensorManager mSensorManager ; private AcceleroFilter xFilter = new AcceleroFilter ( ) ; private AcceleroFilter yFilter = new AcceleroFilter ( ) ; private AcceleroFilter zFilter = new AcceleroFilter ( ) ; private double xFiltered ; private double yFiltered ; private double zFiltered ; private float [ ] orientationValues = new float [ 3 ] ; private float [ ] rotation = new float [ 16 ] ; private double startTime ; private double elapsedTime ; private double oldElapsedTime ; private double velocity = 0 ; private double oldVelocity = 0 ; private double noVelocityCounter = 0 ; private double correctedVelocity ; private double oldCorrectedVelocity = Double . NaN ; private double oldOldCorrectedVelocity = Double . NaN ; private double height ; private double oldHeight ; private Chronometer chrono ; long timeWhenStopped = 0 ; long elapsedMillis ; int secs ; int currentmin ; int lastmin ; private View view ; private ImageButton startButton ; private TextView txtStart ; private ImageButton pauzeButton ; private TextView txtPauze ; private ImageButton stopButton ; private TextView txtStop ; private ImageButton resetButton ; private TextView txtReset ; private TextView txtHeight ; private TextView txtSnelheid ; private String locatie ; private String descriptie ; private String Uid ; JSONObject jsonResponse ; private TextToSpeech SayTime ; @ Override public View onCreateView ( LayoutInflater inflater , @ Nullable ViewGroup container , @ Nullable Bundle savedInstanceState ) { } @ Override public void onClick ( View v ) { } private void showStopButton ( ) { } private void hideStopButton ( ) { } private void StartSensor ( ) { } @ Override public final void onAccuracyChanged ( Sensor sensor , int accuracy ) { } public void onSensorChanged ( SensorEvent event ) { } private void speakText ( ) { } private void savePicture ( ) { locatie = DescriptionFragmentSession . getLocation ( ) ; descriptie = DescriptionFragmentSession . getDescription ( ) ; try { if ( ( DatabaseData . PhotoString ) == null ) return ; String username = userData . getJSONObject ( "user" ) . getString ( "name" ) ; String name = new SimpleDateFormat ( "ddMMyyyy_HHmm" ) . format ( new Date ( ) ) ; File Drawn = new File ( ( ( ( Environment . getExternalStorageDirectory ( ) . toString ( ) ) + "//ClimbUP//" ) + username ) ) ; Drawn . mkdirs ( ) ; File Drawing = new File ( Drawn , ( name + ".jpg" ) ) ; FileOutputStream out = new FileOutputStream ( Drawing ) ; ByteArrayOutputStream arrayOutputStream = new ByteArrayOutputStream ( ) ; Bitmap bitmap = BitmapFactory . decodeFile ( PhotoString ) . copy ( RGB_565 , true ) ; Typeface tf = Typeface . create ( "sans-serif-condensed" , BOLD ) ; int x = 50 ; int y = 75 ; int size = 32 ; Canvas canvas = new Canvas ( bitmap ) ; Paint paint = new Paint ( ) ; paint . setStyle ( FILL ) ; paint . setColor ( WHITE ) ; paint . setTypeface ( tf ) ; paint . setTextSize ( convertToPixels ( getActivity ( ) . getApplicationContext ( ) , size ) ) ; String text = locatie ; Rect textRect = new Rect ( ) ; paint . getTextBounds ( text , 0 , text . length ( ) , textRect ) ; String text2 = descriptie ; Rect textRect2 = new Rect ( ) ; paint . getTextBounds ( text2 , 0 , text2 . length ( ) , textRect2 ) ; <START_BUG> String text3 = "Testing3" ; <END_BUG> canvas . drawText ( text , x , y , paint ) ; canvas . drawText ( text2 , x , ( y + ( textRect . height ( ) ) ) , paint ) ; canvas . drawText ( text3 , x , ( ( y + ( textRect . height ( ) ) ) + ( textRect2 . height ( ) ) ) , paint ) ; Paint stkPaint = new Paint ( ) ; stkPaint . setTypeface ( tf ) ; stkPaint . setStyle ( STROKE ) ; stkPaint . setStrokeWidth ( ( size // 10 ) ) ; stkPaint . setColor ( BLACK ) ; stkPaint . setTextSize ( convertToPixels ( getActivity ( ) . getApplicationContext ( ) , size ) ) ; canvas . drawText ( text , x , y , stkPaint ) ; canvas . drawText ( text2 , x , ( y + ( textRect . height ( ) ) ) , stkPaint ) ; canvas . drawText ( text3 , x , ( ( y + ( textRect . height ( ) ) ) + ( textRect2 . height ( ) ) ) , stkPaint ) ; bitmap . compress ( JPEG , 100 , arrayOutputStream ) ; byte [ ] imageArray = arrayOutputStream . toByteArray ( ) ; out . flush ( ) ; out . close ( ) ; Intent mediaScanIntent = new Intent ( Intent . ACTION_MEDIA_SCANNER_SCAN_FILE ) ; mediaScanIntent . setData ( Uri . fromFile ( Drawing ) ) ; getActivity ( ) . sendBroadcast ( mediaScanIntent ) ; DatabaseData . PhotoString = Drawing . getPath ( ) ; DatabaseData . PhotoString = Base64 . encodeToString ( imageArray , DEFAULT ) ; } catch ( Exception e ) { Toast . makeText ( getActivity ( ) . getApplicationContext ( ) , "Unable<seq2seq4repair_space>to<seq2seq4repair_space>edit<seq2seq4repair_space>picture" , LENGTH_SHORT ) . show ( ) ; } } private int convertToPixels ( Context context , int nDP ) { } class MyAsyncTask extends AsyncTask < Void , Void , Void > { private ProgressDialog progressDialog = new ProgressDialog ( getActivity ( ) ) ; protected void onPreExecute ( ) { } @ Override protected Void doInBackground ( Void ... params ) { } protected void onPostExecute ( Void v ) { } @ Override protected void onCancelled ( ) { } } }

Fix:
String text3 = ( String . format ( "%.2f" , height ) ) + "m" ;