Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Freeplane: opções de configurações do ambiente de trabalho dos mapas para A3 e A4. #1771

Open
xraylanx opened this issue Apr 5, 2024 · 5 comments

Comments

@xraylanx
Copy link

xraylanx commented Apr 5, 2024

Is your feature request related to a problem? Please describe.
A clear and concise description of why you need it. Ex. When I want [...] I can not get it done because of [...]

Additional context
Add any other context or screenshots about the feature request here.

@xraylanx
Copy link
Author

xraylanx commented Apr 5, 2024

the freeplane does not have a limit to the map creation environment, it increases infinitely. I would like to format the project page to A4 or A3 size. Currently, it is only possible to make this configuration for printing, but I would like to view the page size during preparation to better organize it.

@euu2021
Copy link
Contributor

euu2021 commented Apr 7, 2024

An idea is to make the Map Overview in the proportion of a A4, activate Spotlight, and then you will be able to see how the map will fit. For example, this is how this map would fit in landscape:

image

@xraylanx
Copy link
Author

xraylanx commented Apr 7, 2024

How to configure the size of the map overview? @euu2021

@euu2021
Copy link
Contributor

euu2021 commented Apr 8, 2024

Use this script:

import javax.swing.JScrollPane
import java.awt.Rectangle;

import org.freeplane.features.mode.Controller
import org.freeplane.view.swing.map.MapView

MapView mapView = Controller.currentController.mapViewManager.mapView

JScrollPane findScrollPaneParent(java.awt.Component component) {
    while (component != null && !(component instanceof JScrollPane)) {
        component = component.getParent()
    }
    return component as JScrollPane
}

JScrollPane mapViewScrollPane = findScrollPaneParent(mapView)

width = 200
height = 200

Rectangle newBounds = new Rectangle(00, 00, width, height)

mapViewScrollPane.parent.setMapOverviewBounds(newBounds)

Set the width and height at the lines:

width = 200
height = 200

The map overview will be created in the top left corner, but you can move it to wherever you want.

To learn how to use scripts, see this page.

@xraylanx
Copy link
Author

xraylanx commented Apr 8, 2024

Thank you very much for your help, friend!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants