Looking for help with GUI on FreeAPS Loop

Hi Everyone!
I am using a version of the FreeAPS Loop on iPhone. I am wondering if any of the Loop gurus here can help me with something…

This is a screenshot of my iPhone when I bolus. I am trying to figure out a way to make the bolus amount text bigger here, just while bolusing. (The part I boxed in red below.)

Just to make it easier to see when I do a bolus! You shouldn’t need to have your glasses on just to do a bolus, right? :grinning:

I know where the string is set, but can’t figure out how to make it bigger during the bolus.

From this file:
SOURCE\LoopWorkspace\Loop\Loop\Views\BolusProgressTableViewCell.swift

private func updateProgress() {
guard !disableUpdates, let totalUnits = totalUnits, let unit = unit else {
return
}

    let totalUnitsQuantity = HKQuantity(unit: unit, doubleValue: totalUnits)
    let totalUnitsString = quantityFormatter.string(from: totalUnitsQuantity, for: unit) ?? ""

    if let deliveredUnits = deliveredUnits {
        let deliveredUnitsQuantity = HKQuantity(unit: unit, doubleValue: deliveredUnits)
        let deliveredUnitsString = quantityFormatter.string(from: deliveredUnitsQuantity, for: unit) ?? ""

        progressLabel.text = String(format: NSLocalizedString("Bolused %1$@ of %2$@", comment: "The format string for bolus progress. (1: delivered volume)(2: total volume)"), deliveredUnitsString, totalUnitsString)

        let progress = deliveredUnits / totalUnits
        UIView.animate(withDuration: 0.3) {
            self.progressIndicator.progress = progress
        }
    } else {
        progressLabel.text = String(format: NSLocalizedString("Bolusing %1$@", comment: "The format string for bolus in progress showing total volume. (1: total volume)"), totalUnitsString)
    }
}

Not sure who all the Loop experts are. I know these are a few of the many here who do Loop or who have done it in the past. @dm61 , @bkh , @CatLady , @Trying , @ClaudnDaye

Thanks!

1 Like

Just trying to read the code snip, it looks like you’ve found the code that decides the text characters to print, and stuffs them into the string at progressLabel.text, but it’s not clear where the code is that renders that text string out onto your screen, with characteristics like size, font, and boldness. I’d say keep looking for some place that declares the properties of the progressLabel, and code that somehow actually prints out the progressLabel contents. Who knows, maybe the progressLabel has properties other than “text” that store attributes like size and font and boldness and so on, initialized once somewhere.

1 Like

Here is what I think you may try. In search, enter progressLabel and click on the result that comes with a little pen&brush symbol. You should then see what is called a “View” where properties of the label can then be adjusted in the menus on the right-hand side. For example, you can see System Bold 15.0 is set there. Attached is a screenshot from Xcode that may help.

I have never messed with Views so I do not know if e.g. simply changing the font size would work or if you’d need to do more.

4 Likes

Thanks a bunch, I will give it a try!

I am not sure if I am the only one who has this issue, but I just want to see the amount number a little bigger! I just always worry about giving the wrong amount.

2 Likes

@Eric If you haven’t already, you may want to go on the Loop github site and PM Marion Barker about how best to do it. She does most/all of the UI documentation for Loop dev and I’m pretty sure she’d be able to point right at the place needed.

2 Likes

Thanks @TomH. I think I may have the GUI part figured out, except then I started getting build errors. And I have not figured that out yet.

line 39: /usr/local/bin/carthage: No such file or directory
Command PhaseScriptExecution failed with a nonzero exit code

Any ideas on that? :arrow_up: The reference to /usr/local/bin/carthage which does not exist. That is a new error.

1 Like

@Eric I’m not familiar with FreeAPS, Loop dev recently moved to Carthage “free” building, though there was a hiccup in the process at one point. I recall there was an issue with the Carthage version having to do with, I believe, the Xcode version. Other than that, I’m out of my depth. Best wishes for resolving…

2 Likes

Thanks @TomH. I deleted everything except my project and then I uninstalled Xcode.

I’m downloading Xcode again and I’m going to reinstall it and see if anything changes.

Good suggestion by @TomH. I’m also not familiar with FreeAPS. Hwr, if I’m not mistaken, I believe Marion Barker was using FreeAPS for a while so she may be able to help with the build error.

1 Like