Ok, so, I've been beating my head into the Forms API documentation for a bit. And I understand the basic structure of how to *create* forms in the new 4.7 Forms API. I'm a bit confused, however, about how to *alter* existing forms.
Particularly, I'm trying to alter the gmap module form so that it doesn't ask people to enter in their street address information in the user>edit>location form. Normally, I would do this using a hack (see the commented lines below):
<?php
$form = array(1 => array());
//the hack begins here -- I'm commenting this next line out, because I don't want people to feel pressured to put in their street address ajwwong
//$form[0]['location'] = location_form(array('street', 'city', 'province', 'postal_code', 'country'), (isset($user->location) && !_location_is_empty($user->location)) ? location_api2form($user->location) : array('country' => variable_get('location_default_country', 'us')));
// and I'm adding this line below -- the new "hacked" line -- without the "street" information field.
$form[0]['location'] = location_form(array('city', 'province', 'postal_code', 'country'), (isset($user->location) && !_location_is_empty($user->location)) ? location_api2form($user->location) : array('country' => variable_get('location_default_country', 'us')));
$form[0]['location']['#type'] = 'fieldset';
$form[0]['location']['#title'] = t('Location');