128 Commits

Author SHA1 Message Date
Justin Kunimune
bd07cf8e11 improve SVG descriptions 2024-01-09 15:03:09 -05:00
Justin Kunimune
71e99191c9 I don't know when this changed 😭 2024-01-09 13:16:44 -05:00
Justin Kunimune
00c7fd9193 new blanker world map template
to complete the trifecta.  it has rivers, and no political borders.
2024-01-09 13:16:23 -05:00
Justin Kunimune
3d35c305b6 fix fed up file description 2024-01-09 13:15:10 -05:00
Justin Kunimune
b417e0ba18 fix weird coastlines
they were getting Zed by fuse_russia.
2024-01-08 22:02:03 -05:00
Justin Kunimune
990205bec6 thin lines between sub-country units
I ended up not really using the new political boundary data structure.  oh, well.
2024-01-08 21:42:44 -05:00
Justin Kunimune
793e5e8be6 refactor political map generation
I refactord the ploitical map generation.  I broke the plot_political_shapes function into two parts: the loading part (which generates a nested dictionary) and the plotting part.  this will enable me to process the data between those two steps.  I haven't gotten to that yet, but that's my next step in thinning the lines between geounits within countries.
2024-01-07 16:30:16 -05:00
Justin Kunimune
eb2834bc60 delete Population.svg
I still think this bubble plot is a good idea, but this is not the way I want to go about it and it's cluttering up the directory.  someday I'll rite a python script outside of github to modify Template provinces.svg with population bubbles.
2024-01-07 09:58:08 -05:00
Justin Kunimune
1bd58a2669 EU and united kingdoms
I enhanced the hierarchical stuff to lalow supranational entities and sub-country geounits.  now the provinces map has england, srpska, french guiana, and more.  the only issue is the borders between geounits are thick but I want them to be thin like province borders.  so that's the next step.
2024-01-07 09:55:00 -05:00
Justin Kunimune
9958526b2c keeping the old graticule as an option
after I implemented the sparse graticule thing at th epoles, I realized some people mite like to have the old graticule behavior in some situations.  I added an option to graticule.txt to do just that.  now you can set it to make the poles look however you want.
2023-12-29 16:12:57 -10:00
Justin Kunimune
59e1605016 make maps work better in Wikipedia
apparently compound CSS selectors don't work in the Wikimedia Commons' SVG renderer?  also, href isn't supported, so you have to use xlink:href.  but xlink:href is deprecated so you actually have to use both...
2023-12-28 22:20:55 -10:00
Justin Kunimune
9c1d6af752 bubble plots
I added a feature to generate a population bubble plot.  I want to make it do separate bubbles for the different provinces of big countries, but for now those bubbles are all the same size.  I need to find some good databases for those numbers.
2023-12-24 21:05:25 -10:00
Justin Kunimune
f2180c7be5 improve SVG descriptions
I realized that "110m" doesn't mean that data are precise to 110km; it means that it's suitable for 1:110M scale.  oops.  I deleted the corresponding false statements and also added a bunch of references to natural earth.
2023-12-24 20:55:15 -10:00
Justin Kunimune
e74328e014 India was in here the whole time‽
apparently I do have province borders for India and I just missd it.  that's definitely going in.
2023-12-24 20:43:29 -10:00
Justin Kunimune
4b1dc67c34 remove south africa's provinces
I was at first operating on the principle of the more resolution the better, but then I realized that South Africa is really not a big country.  23rd in population, 24th in area.  I don't know why it has provincial resolution in this dataset and argentina, mexico, algeria, DRC, saudi arabia, kazakhstan, and india don't.  but the fact that it does is slitely insulting.  I'm removing it from the provinces map because I can't imagine a situation where it would make sense to draw these lines but not the others for which I don't have data.
2023-12-23 07:03:23 -10:00
Justin Kunimune
769f5e5644 ISO alpha2 codes for dependencies 2023-12-22 17:46:19 -10:00
Justin Kunimune
62de75cba3 clip maps to background
this is so good.  I must have thaut of this at some point in the past, but it wasn't much of an option until I added backgrounds.  the geographic content now clips to the background, so if you have a map with a lot of interruptions and there are lines that didn't get cut properly or shapes enclosing singularities such that there's gunk extending off the map, it will be invisible.  the clipping path hides it.  it looks incredible instead of always garbage!  it doesn't fix all such issues of course – there are often excess lines inside the geographic region that won't get removed by clipping.  but it gets like a lot of them.  I can't get over how much better these maps look out of the box now than they did  a year ago.
2023-12-22 11:40:33 -10:00
Justin Kunimune
98a22a7304 begone, line!
I set the political svgs to remove the divide thru russia at the antimeridian.  I'm a bit surprised I didn't try this sooner since it's just kind of an ugly erroneus line in most of my map projections.  unfortunately, the solution I found doesn't work for the physical maps.  that's a bit of a bummer for the tissot ellipse maps specificly.  however, it was most notable (and most potentially confusing) in the blank political templates, so I'm very glad that I fixd that.
2023-12-21 21:21:02 -10:00
Justin Kunimune
9912d00ae7 he, she, me, indicatrices.
I dubble-checked the terminology, and actually an indicatrix is a single circle and the plural is indicatrices.  I think I had this exact same revelation in the past, but the end result is that I was rite before.  thankfully, I did also find out that there's a preexisting non-terrible alternative, which is to simply call them Tissot's ellipses.  which is good because now I don't have to come up with my own (I was leaning toward "Tissot's indicators").  I went ahead and changed the terminology to "ellipse" everywhere in the SVGs.
2023-12-21 18:45:55 -08:00
Justin Kunimune
0ddd0609ba I don't think indicatrices is a real word.
idk how I got "Tissot's indicatrices" in my head, but this thing is called "Tissot's indicatrix".  I mean, "indicatrix" isn't a real word either but it's better than "indicatrices".
2023-12-21 18:25:42 -08:00
Justin Kunimune
c0d7abd448 clarify some SVG descriptions
also remove simplified because I think it's just a lower-resolution version of basic?  users can darn well simplify their own maps.  besides, if I wanted such a thing I could get it more effectively by just using the 110km dataset.
2023-12-21 18:19:19 -08:00
Justin Kunimune
273b4fea64 less is more
I made varius improvements to the input SVG maps.  I changed the provinces map to use 50km borders rather than 10km borders, reducing its filesize by a factor of 10.  this does unfortunately mean that I can *only* have province borders for seven or so countries, not even including argentina.  that sucks, but to be fair I really didn't need admin1 boundaries for, like, armenia.  I just wish I could have them for more like the top twenty biggest countries.  I've decided that the decrease in filesize is well worth it, tho.  25MB was just too big for an SVG, and made it rather difficult to use for practical purposes (not to mention, it was about 10% of the total program size).

I also made it so that all countries in the political maps are classed with both their ISO 3166 A3 code and their ISO 3166 A2 code, so that you can use either in the stylesheet.  it seems the A2 codes are more common, so I thaut it worth including.

I removed the circles for Cyprus No-mans-land and the Siachen Glacier.  even tho they are both decently inhabited, neither of them has any presence in international politics, so I find it very unlikely anyone using these maps will even have data to put on them.

I removed some empty parentheses that were appearing next to Palestine's name.  I fleshd out the descriptions to include more information.  and I added more comments to the CSS.
2023-12-21 12:07:56 -08:00
Justin Kunimune
6960477da6 restyle example styles in template SVGs 2023-12-20 17:45:06 -08:00
Justin Kunimune
da6cbe8dd0 I swear I got rid of this stupid grey rectangle
idk it used to be text I gess?  but I found this years ago; why is it still here‽
2023-12-15 20:08:00 -08:00
Justin Kunimune
a71ad616bc no more prime meridian!
I dislike it and don't kno why I really put it there in th efirst place.  I suppose just to have a vertical analog for the equator but who needs that.
2023-12-15 19:44:53 -08:00
Justin Kunimune
114eb870c8 I missed one 2023-12-15 12:32:54 -08:00
Justin Kunimune
b88c3fae3e simplify SVGs
I tried to make my SVGs more robust in terms of only using features supported on a wide variety of platforms.  in particular, it turns out nested CSS blocks may not be a core CSS thing... they're a Sass thing?  but chrome and firefox both seem to interpret it correctly automaticly.  in any case, I got rid of that and told the user to do their circle showing manually.  I also deleted all these namespaces and metadata tags because it seems like intellij is having trubble resolving their sources and idk what's the point of including them in the first place.  all of this information is either already included or is better given in supplementary files.  I also added more background rectangles.
2023-12-14 21:03:25 -08:00
Justin Kunimune
2e5205e379 attention to detail
I went thru and corrected numerus inspection warnings.  I'd say most of it is correcting typos.  I also removed a bunch of unused variables and methods (and even a cupple of files), adjusted varius stylings, improved a few docstrings, made local variables where one quantity was getting calculated multiple times, and cetera.  the spiciest thing was that I refatord the part where it saves a screenshot of the graphs in the MapAnalyzer; previusly it was bizzy-waiting for the GUI thread to finish taking the screenshot, which was probably fine, but now it uses FutureTask.get(), which is probably faster and definitely cleaner.  I also deleted the code for the two-point equalized projection because it was bad and didn't work very well (to be precise it wasn't in use after I removed it from the projection list a few days ago so this is just codifying that renunciation).  I also made AuthaGraph fixd instead of parameterized because I think that was just a mistake.
2023-12-14 14:08:14 -08:00
Justin Kunimune
f20ce46bcd add outline to Compound.svg
it looks weerd with a graticule but without a border.
2023-11-25 11:33:16 -05:00
Justin Kunimune
bb02f46720 (rectangular) Backgrounds!
I made it so that background rectangles in the input SVGs fit themselves to the bounding box of the new projection in the output SVGs.  this may seem a strange amount of work to go thru seeing as the result is effectively the same as what I got before using <rect x="0" y="0" width="100%" height="100%" />.  but of course this is bilding toward a more general background shape implementation.  this is a necessary groundwork for that advance – now rectangles are parsed when the SVG is loaded and respond to the projection when the map is saved.  the input SVGs also have background rectangles that more naturally match the input.  now all that's left to do is implement those shapes!
2023-11-14 14:21:37 -05:00
Justin Kunimune
c488154e58 slightly adjust css for readability 2023-10-14 17:24:37 -04:00
Justin Kunimune
2dd268ab1c move all circles to front of map
I had hoped spacing the circles would make them stop getting obscured by the normal borders of other countries, but alas.  now the circles are garanteed to be in front of all normal boundaries; it just makes the SVG file a little bit bigger.
2023-10-01 19:41:58 -04:00
Justin Kunimune
4b909b0266 revise Supermap.svg styling
not sure why I'm putting so much work into an input may I may never use but whatever.  the main thing to note here is that I've done away with the use of label rank to determine label size, because as it turns out that's not at all what it's supposed to do.
2023-10-01 18:04:19 -04:00
Justin Kunimune
3618c97939 remove comicly precise radii 2023-09-28 15:56:11 -06:00
Justin Kunimune
fe0f504775 more detailed title text
now it uses fewer abbreviations and includes the sovereign in parentheses when you mouse over cuontries in the template.
2023-09-12 20:06:04 -04:00
Justin Kunimune
746a6e0a08 patch holes in province map
I found out why there were missing shapes in the province map.  it was because ISO 3166 2 codes are not unique in the natural earth dataset.  so I left those as classes but switchd to unique ones as ids.
2023-09-10 09:51:32 -04:00
Justin Kunimune
f39559e25a consolidate SVG structure
I made it so a group will never contain only one element; the group attributes just get moved onto the containd class.  I think it's way easier to read the SVG files as plaintext now.   I also got rid of all the d="" paths that had cropd up.  I also figured out that it looks way better to put the <title/> in the same group as the paths rather than putting them inside the paths.
2023-09-10 09:23:47 -04:00
Justin Kunimune
c70d4fb5f0 use spherical area to assine circles
not equirectangular area
2023-09-10 08:44:42 -04:00
Justin Kunimune
9ff4f737b4 many minor improvements to input maps
make the SVG metadata more specific and accurate.  make Template countries.svg have coarser borders, but also make sure it includes all countries no matter how small, but also make sure it doesn't circle purely military installations no matter how big.
 restyle to make all countries be gray unless otherwise specified.  restyle to make circles disappear and reappear when colored in automaticly.  change some stroke widths and background opacities.  fix some indentation.  also, update my GitHub URL
2023-09-10 08:41:26 -04:00
Justin Kunimune
c3965dc44c make SVG IDs unique
I was hoping this would fix the holes in my maps, but it didn't.
2023-09-06 14:00:39 -04:00
Justin Kunimune
6c5f0550e4 more robust hierarchial SVGs
I made it generate SVG with a more robust nesting structure that allowd me to generalize to a well-organized admin-1 map.  I also went ahead and split Political.svg from Advanced/Template countries.svg, so now one has labels and the other has circles/tooltips.
2023-09-05 14:37:59 -04:00
Justin Kunimune
325e17b181 hover text!
I ended up refactoring kind of a lot to do this, because I would have otherwise needed to duplicate some code to get each country's name.  and this way is much better.  less duplicated code, no need for SimpleNamespaces.
2023-09-04 16:08:54 -04:00
Justin Kunimune
24b6ee1bc5 rearrange countries
to put the circles next to the owning country
2023-09-04 14:00:41 -04:00
Justin Kunimune
f46e2f7bc1 sorry, Antarctica
I made it red and forgot to change it back
2023-09-04 13:53:26 -04:00
Justin Kunimune
4e6a8d910f remove redundant classes
this makes the political files just a little bit smaller.
2023-09-04 13:22:09 -04:00
Justin Kunimune
1113500e7d sorry, Tuvalu
I apparently missed it when I was coloring in the countries, so it was grey.
2023-09-04 13:11:59 -04:00
Justin Kunimune
d35e315392 make Bir Tawil grey
I rearranged some of the styling stuff to make all countries grey by default.  while I was at it I updated the class names for the supermap because oh my lord were they incomprehensible.  I mean, "admin"‽
2023-09-04 12:31:23 -04:00
Justin Kunimune
97340cd86b remove death valley
depressions just look out of place on the map and aren't that interesting.
2023-09-04 11:45:21 -04:00
Justin Kunimune
b4cf30c59e no more randomness
I just want the last few digits of the labels to stop showing up in every diff.
2023-09-04 11:32:21 -04:00
Justin Kunimune
022a7c5c78 fix circles
I got the circles good.  first of all, none were appearing because the code deciding when to add them was all inverted.  more interestingly, I realized I can't put them on the same layer as the other country shapes because then they'll get obscured by stuff.  so I moved the circles to their own group.  I also made them much smaller.  finally, I made the Supermap.svg file a tiny bit smaller by styling borders more efficiently.
2023-09-04 11:28:19 -04:00