From da89e44e7eb64917ff6b289f315b41eb2689a13f Mon Sep 17 00:00:00 2001 From: taufiq Date: Sun, 14 Apr 2024 17:28:26 +0800 Subject: [PATCH 1/2] feat: Do not truncate on long texts Key information are being truncated when left to display only up-to 80 characters for the descriptions of the mods. --- .../seedu/address/logic/commands/module/ListModulesCommand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java b/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java index 46900ae3cf7..8afbfb5c75c 100644 --- a/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java +++ b/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java @@ -38,7 +38,7 @@ public CommandResult execute(Model model) throws CommandException { sb.append("List of modules with prefix: ").append(this.modulePrefix).append("\n"); for (Module m : modules) { sb.append(m.getModuleCode().getCode()).append(" : "); - sb.append(StringUtil.truncate(m.getDescription().getValue(), 80)).append("\n"); + sb.append(m.getDescription().getValue()).append("\n\n"); } return new CommandResult(sb.toString()); } From 07d3f4fcfab75211841ca11c8cce1ff293c0bc78 Mon Sep 17 00:00:00 2001 From: taufiq Date: Sun, 14 Apr 2024 17:28:57 +0800 Subject: [PATCH 2/2] feat: Wrap long texts Long texts are wrapped so it all fits within the width of the result display so users only need to scroll vertically and not horizontally --- .../address/logic/commands/module/ListModulesCommand.java | 1 - src/main/resources/view/ResultDisplay.fxml | 5 ++--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java b/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java index 8afbfb5c75c..5efd2a217bf 100644 --- a/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java +++ b/src/main/java/seedu/address/logic/commands/module/ListModulesCommand.java @@ -5,7 +5,6 @@ import java.util.List; -import seedu.address.commons.util.StringUtil; import seedu.address.logic.commands.Command; import seedu.address.logic.commands.CommandResult; import seedu.address.logic.commands.exceptions.CommandException; diff --git a/src/main/resources/view/ResultDisplay.fxml b/src/main/resources/view/ResultDisplay.fxml index 01b691792a9..c6c34bb6504 100644 --- a/src/main/resources/view/ResultDisplay.fxml +++ b/src/main/resources/view/ResultDisplay.fxml @@ -3,7 +3,6 @@ - -