<commit_before>/** Copyright (C) 2013 <NAME> - Released under terms of the AGPLv3 License */
#ifndef GCODEEXPORT_H
#define GCODEEXPORT_H

class GCodeExport
{
private:
    FILE* f;
    double extrusionAmount;
    double extrusionPerMM;
    double retractionAmount;
    double extruderSwitchRetraction;
    double minimalExtrusionBeforeRetraction;
    double extrusionAmountAtPreviousRetraction;
    Point3 currentPosition;
    Point extruderOffset[16];
    int currentSpeed, retractionSpeed;
    int zPos;
    bool isRetracted;
    int extruderNr;
    int currentFanSpeed;
    int flavor;
    
    double totalFilament;
public:
    double totalPrintTime;
    
    GCodeExport()
    : currentPosition(0,0,0)
    {
        extrusionAmount = 0;
        extrusionPerMM = 0;
        retractionAmount = 4.5;
        minimalExtrusionBeforeRetraction = 0.0;
        extrusionAmountAtPreviousRetraction = -10000;
        extruderSwitchRetraction = 14.5;
        extruderNr = 0;
        currentFanSpeed = -1;
        
        totalPrintTime = 0.0;
        totalFilament = 0.0;
        
        currentSpeed = 0;
        retractionSpeed = 45;
        isRetracted = false;
        memset(extruderOffset, 0, sizeof(extruderOffset));
        f = NULL;
    }
    
    ~GCodeExport()
    {
        if (f)
            fclose(f);
    }
    <commit_msg>Start in the retracted state, so the first thing added at the skirt is a G1 E0 F{retract_speed}<commit_after>/** Copyright (C) 2013 <NAME> - Released under terms of the AGPLv3 License */
#ifndef GCODEEXPORT_H
#define GCODEEXPORT_H

class GCodeExport
{
private:
    FILE* f;
    double extrusionAmount;
    double extrusionPerMM;
    double retractionAmount;
    double extruderSwitchRetraction;
    double minimalExtrusionBeforeRetraction;
    double extrusionAmountAtPreviousRetraction;
    Point3 currentPosition;
    Point extruderOffset[16];
    int currentSpeed, retractionSpeed;
    int zPos;
    bool isRetracted;
    int extruderNr;
    int currentFanSpeed;
    int flavor;
    
    double totalFilament;
public:
    double totalPrintTime;
    
    GCodeExport()
    : currentPosition(0,0,0)
    {
        extrusionAmount = 0;
        extrusionPerMM = 0;
        retractionAmount = 4.5;
        minimalExtrusionBeforeRetraction = 0.0;
        extrusionAmountAtPreviousRetraction = -10000;
        extruderSwitchRetraction = 14.5;
        extruderNr = 0;
        currentFanSpeed = -1;
        
        totalPrintTime = 0.0;
        totalFilament = 0.0;
        
        currentSpeed = 0;
        retractionSpeed = 45;
        isRetracted = true;
        memset(extruderOffset, 0, sizeof(extruderOffset));
        f = NULL;
    }
    
    ~GCodeExport()
    {
        if (f)
            fclose(f);
    }
    
{'fraction_non_alphanumeric': 0.07389879868947943, 'fraction_numerical': 0.026210411357844923, 'mean_word_length': 2.3759213759213758, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7097472', 'n_tokens_mistral': 907, 'n_tokens_neox': 842, 'n_words': 201}